Ideal Linear Prediction of One Time Series Given Another
2 次查看(过去 30 天)
显示 更早的评论
I have two data time series arrays, p (the predictors) and v (the values), each of the same length len.
What is the simplest way to create an ideal, nth-order, causal linear predictor based on the relationship of the predictors and the values and then use it to make a causal prediction of each successive value of v(t) given the all of the predictor data up until that timepoint in the predictor time series, but none of the later datapoints, ie p(1:t)?
In making a prediction of a single time series given all of the prior datapoints in the same series, this can be done using the linear predictor coefficients function to generate a filter, and then using the filter to create the prediction, as described in the documentation for the function lcp: https://www.mathworks.com/help/signal/ref/lpc.html
What is the best function/method for doing this when you have one (or more) time series, to use to predict another time series that is not a member of the group of predictors?
Is there a matlab function that is to crosscorrelation what lpc is to autocorrelation?
Thank you?
1 个评论
Benjamin Thompson
2022-1-24
The curve fitting toolbox has a function fit(), or the curve fitting tool for a more interactive experience.
This article has the mathematical background on fitting a line to data:
There are other toolboxes with similar features, see the article "Linear Regression Workflow" in the help, using the Statistics toolbox.
In general MALTAB the polyfit function should always be available, just fitting a polynomial of order 1 to your data.
回答(1 个)
Benjamin Thompson
2022-1-24
Submitting again as an answer...
The curve fitting toolbox has a function fit(), or the curve fitting tool for a more interactive experience.
This article has the mathematical background on fitting a line to data:
There are other toolboxes with similar features, see the article "Linear Regression Workflow" in the help, using the Statistics toolbox.
In general MALTAB the polyfit function should always be available, just fitting a polynomial of order 1 to your data.
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!