1 %> @brief LASSO feature selection
4 %> Number of features to be selected
10 o.classtitle = 'LASSO';
15 methods(Access=protected)
16 function log = do_use(o, data)
19 irerror('LASSO feature selection works with 2-class datasets only!');
23 L = abs(lasso(ds.X, Y, -o.nf_select, false));
25 % Sorts in descending order of importance and trims
28 [vv, ii] = sort(coeff, 'descend');
29 if numel(ii) > o.nf_select
30 ii = ii(1:o.nf_select);
32 grades = zeros(1, ds.nf);
33 grades(ii) = coeff(ii);
42 log.yname = 'LASSO coefficient';
Log generated by an as_fsel class.
Analysis Session that produces a log_as_fsel.