Hi, everyone!

Recently, I’m really comfused about “Elastic net” using CVX package. Here is the details:

I compared the results from lasso.m (MATLAB buld-in function) and glmnet.m (glmnet_matlab tool; https://web.stanford.edu/~hastie/glmnet_matlab/). I found their results great different. Especially, the results from CVX seemd not so sparse (some of Betas should be zero), although there were lots of small number, such as -3.07e-09.

The scripts of “Elastic net” problem in CVX are as follow:

So, I want to know how can I get the “really” sparse results using CVX.

Thanks