plot.SIR | R Documentation |
Display the 10 first eigen values and the estimated index versus Y of the SIR model.
## S3 method for class 'SIR'
plot(x, choice = "", ...)
x |
A SIR object |
choice |
the graph to plot:
|
... |
arguments to be passed to methods, such as graphical parameters (not used here). |
No return value
# Generate Data
set.seed(10)
n <- 500
beta <- c(1,1,rep(0,8))
X <- mvtnorm::rmvnorm(n,sigma=diag(1,10))
eps <- rnorm(n)
Y <- (X%*%beta)**3+eps
# Apply SIR
res = SIR(Y, X, H = 10, graph = FALSE)
# Eigen values
plot(res,choice="eigvals")
# Estimated index versus Y
plot(res,choice="estim_ind")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.