Problem running linear fit y= m*x
古いコメントを表示
how do you run a linear fit for y= m*x. I don't want to use polyfit(x,y,1) as this gives y=mx+b.
回答 (1 件)
Star Strider
2018 年 4 月 22 日
Use the mldivide,\ (link) function:
m = x(:)\y(:);
カテゴリ
ヘルプ センター および File Exchange で Linear and Nonlinear Regression についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!