Learn R Programming

sysid (version 1.0.4)

iv4: ARX model estimation using four-stage instrumental variable method

Description

Estimates an ARX model of the specified order from input-output data using the instrument variable method. The estimation algorithm is insensitive to the color of the noise term.

Usage

iv4(z, order = c(0, 1, 0))

Arguments

z
an idframe object containing the data
order
Specification of the orders: the three integer components (na,nb,nk) are the order of polynolnomial A, (order of polynomial B + 1) and the input-output delay

Value

An object of class estpoly containing the following elements:

Details

Estimation is performed in 4 stages. The first stage uses the arx function. The resulting model generates the instruments for a second-stage IV estimate. The residuals obtained from this model are modeled using a sufficently high-order AR model. At the fourth stage, the input-output data is filtered through this AR model and then subjected to the IV function with the same instrument filters as in the second stage.

References

Lennart Ljung (1999), System Identification: Theory for the User, 2nd Edition, Prentice Hall, New York. Section 15.3

See Also

arx, iv4

Examples

Run this code
mod_dgp <- idpoly(A=c(1,-0.5),B=c(0.6,-.2),C=c(1,0.6),ioDelay = 2,noiseVar = 0.1)
u <- idinput(400,"prbs")
y <- sim(mod_dgp,u,addNoise=TRUE)
z <- idframe(y,u)
mod_iv4 <- iv4(z,c(1,2,2))

Run the code above in your browser using DataLab