Tsls(Input: ITimeSeries,
Period: IMsPeriod,
ConstantValue: Variant,
AROrder: String,
MAOrder: String,
Casewise: MsCasewise,
Explanatories: Array)
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. Exogenous and instrumental variables.
It models the variable using the linear regression (estimation by the instrumental variables methods).
This function can be used only in series calculation mode.
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.
AROrder, MAOrder. Parameters are set in the string view. Specify the numbers or ranges of autoregression or moving average orders separated by commas. The range of autoregression or moving average orders is specified via the sign -. For example: AROrder = 1-3,5.
MAOrder. If the moving average order is set, back-casting can be used to estimate its coefficients. By default the back-casting is used. If the back-casting needs to be disabled, the MAOrder parameter should contain the backcast.No string. For example: MAOrder = "1-4;backcast.No".
Explanatories. Exogenous and instrumental variables are specified via commas. Use the Null value to separate these types of variables. The number of instrumental variables must be not less than the number of exogenous ones.
Formula | Result | Application |
= Tsls({Brazil|BCA[t]}, SetPeriod("01.01.2000","01.01.2015"), Estimate,"","", MsCasewise.Yes, {China|BCA},Null,{Japan|BCA}) | The Brazil|BCA series will be modeled with linear regression method (instrumental variables estimation method) by the following parameters: constant is estimated by the Estimate function, orders of autoregression and moving average are not set, exogenous variable - the China|BCA factor, instrumental variable - the Japan|BCA factor, calculation is executed for the period from 2000 to 2015 treating missing data with the Casewise method. |
It can be used in formulas of calculated series of time series database and in formulas of attribute-based models of modeling container. |
= Tsls(X1,None,"1","2;backcast.No", MsCasewise.Yes,X4,Null,X2, X3)
|
The X1 factor will be modeled using linear regression method (instrumental variables estimation method) by the following parameters: constant is not set, autoregression order is 1, moving average order is 2, to estimate moving average coefficients - backcasting is not used, exogenous variable - the X4 factor, instrumental variables - the X2 and X3 factors, the calculation is executed for the whole period treating missing data with the Casewise method. |
It can be used in model variable-based formulas of modeling container. |
See also:
Functions Available in Expression Editor │ Regression │ IModelling.Tsls │ Instrumental Variables Method