Undefined function 'regress' for input arguments of type 'double'. Issue

1 回表示 (過去 30 日間)
Rahul Panchal
Rahul Panchal 2016 年 4 月 13 日
コメント済み: Rahul Panchal 2016 年 4 月 13 日
I get "Undefined function 'regress' for input arguments of type 'double'. error message when I run following code.
I am using R21014a.
xShrink is 90 x 6 Double. And I ma trying to perform linear regression between column 3 (x value) and 1 (y value),
load xShrink;
col1=(ones(length(xShrink),1));
[B,BINT]=regress(xShrink(:,3),[xShrink(:,1) col1])
figure(1);clf;
x=[15 335];
y=B(1)*x+B(2);
plot(xShrink(:,3),xShrink(:,1),'ko',x,y,'k--');
xlabel('Maximum Machine Pressure (psi)');
ylabel('Maximum Cavity Pressure - Post Gate (psi)');
---------------
I need help to run this code by eliminating "Undefined function 'regress' for input arguments of type 'double'." error.
Thanks

採用された回答

Azzi Abdelmalek
Azzi Abdelmalek 2016 年 4 月 13 日
Check if you have statistics toolbox
  5 件のコメント
Azzi Abdelmalek
Azzi Abdelmalek 2016 年 4 月 13 日
You haven't this toolbox
Rahul Panchal
Rahul Panchal 2016 年 4 月 13 日
thanks

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeLinear Regression についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by