matlab多元线性回归y=a0+a1*x1+a2*x2+a3*x3+a4*x4+a5*x5+a6f*x6+a7*x7+a8*x8+a9*x9+a10*x10y=[320 320 160 710 320 320 320 160 710 320];x1=[2.3 1.7 1.3 1.7 1.7 1.6 1 1.7 1.7 1.7];x2=[2.3 1.7 1.7 1.6 1.7 1.7 1 1.7 1.7 1.7];x3=[2.3 1.7 1.3 1.7 1.7 1.7 2
来源:学生作业帮助网 编辑:六六作业网 时间:2024/12/19 03:44:03
matlab多元线性回归y=a0+a1*x1+a2*x2+a3*x3+a4*x4+a5*x5+a6f*x6+a7*x7+a8*x8+a9*x9+a10*x10y=[320 320 160 710 320 320 320 160 710 320];x1=[2.3 1.7 1.3 1.7 1.7 1.6 1 1.7 1.7 1.7];x2=[2.3 1.7 1.7 1.6 1.7 1.7 1 1.7 1.7 1.7];x3=[2.3 1.7 1.3 1.7 1.7 1.7 2
matlab多元线性回归
y=a0+a1*x1+a2*x2+a3*x3+a4*x4+a5*x5+a6f*x6+a7*x7+a8*x8+a9*x9+a10*x10
y=[320 320 160 710 320 320 320 160 710 320];
x1=[2.3 1.7 1.3 1.7 1.7 1.6 1 1.7 1.7 1.7];
x2=[2.3 1.7 1.7 1.6 1.7 1.7 1 1.7 1.7 1.7];
x3=[2.3 1.7 1.3 1.7 1.7 1.7 2 1.7 1.7 1.7];
x4=[2.3 1.7 1.7 1.7 1.7 1.7 1 1.7 1.8 2.7];
x5=[2.3 1.7 1.7 1.3 1.7 1.4 1 1.7 1.7 1.7];
x6=[2.3 1.7 1.7 1.7 1.5 1.7 1 1.7 1.7 1.7];
x7=[2.3 1.7 1.7 1.7 1.7 1.4 1 1.7 1.7 1.7];
x8=[2.3 1.7 1.7 1.7 1.7 1.7 1 1.7 1.7 1.7];
x9=[2.3 1.7 1.7 1.4 1.7 1.7 1 1.7 1.7 1.7];
x10=[2.3 1.7 1.7 1.7 1.5 1.7 1 1.7 1.7 1.7];
求 a1 a2 a3 a4 a5 a6 a7 a8 a9 a10?
怎么用MATLAB编?
要能复制粘贴到MATLAB里就能运行.
matlab多元线性回归y=a0+a1*x1+a2*x2+a3*x3+a4*x4+a5*x5+a6f*x6+a7*x7+a8*x8+a9*x9+a10*x10y=[320 320 160 710 320 320 320 160 710 320];x1=[2.3 1.7 1.3 1.7 1.7 1.6 1 1.7 1.7 1.7];x2=[2.3 1.7 1.7 1.6 1.7 1.7 1 1.7 1.7 1.7];x3=[2.3 1.7 1.3 1.7 1.7 1.7 2
y=[320 320 160 710 320 320 320 160 710 320];
x1=[2.3 1.7 1.3 1.7 1.7 1.6 1 1.7 1.7 1.7];
x2=[2.3 1.7 1.7 1.6 1.7 1.7 1 1.7 1.7 1.7];
x3=[2.3 1.7 1.3 1.7 1.7 1.7 2 1.7 1.7 1.7];
x4=[2.3 1.7 1.7 1.7 1.7 1.7 1 1.7 1.8 2.7];
x5=[2.3 1.7 1.7 1.3 1.7 1.4 1 1.7 1.7 1.7];
x6=[2.3 1.7 1.7 1.7 1.5 1.7 1 1.7 1.7 1.7];
x7=[2.3 1.7 1.7 1.7 1.7 1.4 1 1.7 1.7 1.7];
x8=[2.3 1.7 1.7 1.7 1.7 1.7 1 1.7 1.7 1.7];
x9=[2.3 1.7 1.7 1.4 1.7 1.7 1 1.7 1.7 1.7];
x10=[2.3 1.7 1.7 1.7 1.5 1.7 1 1.7 1.7 1.7];
X=[ones(length(y),1) x1' x2' x3' x4' x5' x6' x7' x8' x9' x10'];
A=X\y';
a0=A(1);
a1=A(1);
a2=A(2);
a3=A(3);
a4=A(4);
a5=A(5);
a6=A(6);
a7=A(7);
a8=A(8);
a9=A(9);
a10=A(10);