Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Okay thank you. So then as far as I understand you one can not really draw a senseful conclusion/comparison between Lasso vs Ridge when it comes to bias vs variance. Its really data dependent.
Okay got that. But I do not understand why one can not make the two comparable by setting the same regularization strength? Both parameters mean "economically" regularization strength and describe therefore the same. Moreover, I understand that you can bring the coefficients to zero with Ridge. But my argument was that is goes only towards zero and not makes them exactly zero, therefore why can one not say that LASSO makes simpler models because of this property? Thanks for clarification.
@ Adrià: Yes that's true, but the thing is KBinsDiscretizer does this. But pipeline always transforms only the features and not the labels; but using pipeline is important for cross-validation etc. So I need to know on how I can implement it but for the target not on the features.
@ Adrià: Thanks. I think that is correct, but say I want to do a cross-validation which is implemented directly in sklearn. When I do it for preprocessing features, I create a pipline and then feed in this pipeline into cross_validate() or GridSearchCV(). But is there not also a method such that I can use those routine, otherwise it gets very difficult?