Feature selection with Lasso regression

Ғылым және технология

In this video, I show how to use Lasso regression to perform feature selection. Among all the linear models, Lasso regression is the most powerful model for feature selection thanks to its l1 penalty applied to the cost function.
I talk about Lasso regression, feature selection and the most important machine learning models in my online course "Supervised Machine Learning in Python". Link: www.udemy.com/course/supervis...

Пікірлер: 13

  • @AakashGoyal25
    @AakashGoyal252 ай бұрын

    Best explanation I found on Lasso code! Thanks for making this! :)

  • @bheeshmak.s5125
    @bheeshmak.s51259 ай бұрын

    Very well explained..

  • @KN-tx7sd
    @KN-tx7sd Жыл бұрын

    excellent Sir, will it be possible to generate a pipeline to feed in the selected features to the regression or classification model to perform model evaluation and analytics - Thank yiou

  • @yourdatateacher1776

    @yourdatateacher1776

    Жыл бұрын

    Yes, sure. You should use the SleectFromModel object in scikit learn, that selects the most important features selected by a previous model and allows you to feed another model with them.

  • @KN-tx7sd

    @KN-tx7sd

    Жыл бұрын

    @@yourdatateacher1776 Sir, thank you

  • @ajaykushwaha-je6mw
    @ajaykushwaha-je6mw2 жыл бұрын

    i think this video is complete, as we have list of imp feature then we need to drop others non imp. feature from dataframe.

  • @yourdatateacher1776

    @yourdatateacher1776

    2 жыл бұрын

    Thanks! I'm glad you liked it!

  • @dewman7477

    @dewman7477

    2 жыл бұрын

    @@yourdatateacher1776 What are the other methods of feature selection? How do I normally find optimal number of features for my models?

  • @yourdatateacher1776

    @yourdatateacher1776

    2 жыл бұрын

    @@dewman7477 other methods of feature selection are filter-based feature selection and Recursive Feature Elimination. I prefer the latter because it's related to the model logic. The former can be used to remove the less relevant features when your dataset has too many columns.

  • @beautyisinmind2163

    @beautyisinmind2163

    2 жыл бұрын

    if we have multi class classification problem then can we use lasso and ridge for feature selection? or it is only suitable for binary problem only? I mean Iris data set it is a multi class classification problem so can we apply lasso or ridge for it to select features?

  • @yourdatateacher1776

    @yourdatateacher1776

    Жыл бұрын

    @@beautyisinmind2163 with multiclass classification you need to use logistic regression with l1 or l2 penalty functions.

Келесі