OlsR(Input: ITimeSeries,
Period: IMsPeriod,
ConstantValue: Variant,
AROrder: Integer,
MAOrder: Integer,
Casewise: MsCasewise,
Explanatories: Array)
Context. Context. The parameter is used only in Fore.NET
Input. Output variable
Period. Period, at which the method is calculated. If the parameter value is Null, the method is calculated at the entire time period
ConstantValue. Constant used in calculations.
AROrder. Autoregression order
MAOrder. Moving average order
Casewise. Missing data treatment method
Explanatories. Explanatory variables.
It models the variable using the linear regression (OLS estimation). Calculation is executed using the R package.
Use the OlsR method only when series mode of calculation is applied.
Integration with R must be set up in the repository to use this method. For more details about integration setup see the How to Set Up Integration with R?».
ConstantValue. The constant value can be determined by the user or estimated automatically. Use the Estimate function, to estimate values automatically. If the model must be calculated without constant, use the None function.
Explanatories. Elements that correspond to variables specified via comma. Remember that the number of explanatory variables (m) must satisfy the inequality: 0 < m < n-1 for model with constant and 0 < m < n for model without constant, where n is the number of observations in the output variable.
Formula | Result | Application |
= OlsR({Chicago - population[t]}, Null, None, 0, 0, MsCasewise.Yes, {Mexico - population[t]}) | The Chicago - population time series will be modeled by the linear regression method (OLS estimation) at the entire period using the following parameters: no constant is used, autoregression and moving average orders are not set, the Mexico - population time series is used as the explanatory variable, the Casewise missing data treatment method is used. Calculation is executed using the R package. |
It can be used in formulas of calculated series of time series database and model formulas of modeling container that is a child of the time series database. |
= OlsR(X1, SetPeriod(2000, 2015), Estimate, 1, 2, MsCasewise.Yes, X2, X3) | The X1 factor will be modeled using linear regression method (OLS estimation) by the following parameters: calculation period - 2000-2015, constant is estimated with the Estimate function, autoregression order is 1, moving average order is 2, explanatory variables - the X2 and X3 factors, missing data is treated with the Casewise method. Calculation is executed using the R package. |
It can be used in model formulas of modeling container. |
See also:
Functions Available in Expression Editor | R Methods | IModelling.OlsR | Least-Squares Method