Prediction based on previous historical data

8 ビュー (過去 30 日間)
Mekala balaji
Mekala balaji 2015 年 2 月 6 日
回答済み: KUMANAN KUPUSAMY 2017 年 1 月 28 日
Hi, I have Historical data of "Start" and "End". Now, I have "Start" value, but want to predict "End" value. Can some one help me how to predict today's End value based on available Historical "Start & End" and today's Start value (to Predict Today End value). The day is of random type no correlation with time. Please help me some available models using MATLAB. Many many thanks in advance.
Historical Data:
Start End
0.250 0.256
0.240 0.240
0.224 0.240
0.260 0.270
0.240 0.260
And Today Start value: 0.21 (Today End Value: 0.23)
Sincerely, Your's

採用された回答

Guillaume
Guillaume 2015 年 2 月 6 日
編集済み: Guillaume 2015 年 2 月 6 日
You don't have enough points to infer any kind of regression. I mean, if you look at:
data = [0.25 0.256
0.24 0.24
0.224 0.24
0.26 0.27
0.24 0.26];
scatter(data(:, 1), data(:, 2));
there's no pattern to your data.
If you want to do a linear regression anyway:
polystartend = polyfit(data(:,1), data(:, 2), 1); %linear regression
todaystart = 21;
todayend = polyval(polystartend, todaystart)
gives
todayend = 0.22688
  1 件のコメント
Mekala balaji
Mekala balaji 2015 年 2 月 7 日
Sir Thank you so much.
I have upper & lower bound: 0.005 from previous end value. If I predicted today's end is greater than 0005, then I want to restore the just previous end value as today's end value. In this case 0.26 (just for example. but in this no problem). I just want to set this boundary condition (constraint).So, how can I set this condition.
Many many thanks.

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

その他の回答 (2 件)

Udit Gupta
Udit Gupta 2015 年 2 月 6 日
You can use mtlabs Curve Fitting tool (cftool). If you don't have that search for any linear regression or linear interpolation implementation on file exchange.

KUMANAN KUPUSAMY
KUMANAN KUPUSAMY 2017 年 1 月 28 日
can i use current data to predict previous data?

カテゴリ

Help Center および File ExchangeDescriptive Statistics についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by