Lasso回归
clc,clear;
close all;
data=[1.54 1.61 1.62 1.66 1.71 1.72 1.73 1.86 1.92 2 2.21 2.29 2.34...legend('x1参数','x2参数','x3参数')
%拟合
figure
hold on
plot(y,'b');
plot(y1,'r');
legend('原数据','拟合数据')
逐步回归...%逐步回归
function [ Res ] = StageWise( x, y, eps, runtime)
[m,n] = size(x);%数据集的大小
Res = zeros(