Predicting future values in LSTM for time series
이전 댓글 표시
I've been following this tutorial -
And implemented it succesfully too, I wanted to know if i can predict future values (beyond the last date in my time series data), if yes, then how to do it?
Like I have time series data for 90 days, so if i use this model, then It will divide the data into training and testing and then we can get a forecast for testing data but say if i want to find out the prediction for 100th day, how to do it?
댓글 수: 5
Lynn Tung
2020년 4월 28일
Hello, did you find the answer to the question above? I'm also very interested in knowing how to predict the future values using LSTM method.
Thanks,
Abolfazl Nejatian
2020년 4월 30일
dear Aman,
i hope you are fine.
well, you have done this prediction once and it is not really complicated!
as you predict data for your current samples, you can easily predict future samples.
just consider delay(s) for your data and then the minimum delay will explain your prediction horizon.
for instance, if your sequence samples (time series data) is,
1.1 2.8 3.9 1.3 4.5 5.3 6.0 9.1
delay one will be formed your input/target data like below,
Input = 1.1 2.8 3.9 1.3 4.5 5.3 6.0
Target = 2.8 3.9 1.3 4.5 5.3 6.0 9.1
so by giving 1.1 to the network, we anticipate network predict 2.8( which is the next value)
and finally, by giving 9.1 to the network, we anticipate network predict the next future sample(what excatly you want)
Aman Swaraj
2020년 5월 2일
ZAHIR HOSSAIN
2020년 8월 5일
편집: ZAHIR HOSSAIN
2020년 8월 6일
can you upload the full code please, i am having some trouble with rmse calculation, changing ytest gives error "Matrix dimensions must agree." the full code can give me a better understanding for my case. Aman Swaraj
yosra didi
2020년 8월 12일
Could you upload the full code, i am facing a problem, thanks
답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Built-In Training에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!