Description Usage Arguments Examples
Plot method for ordinis fitted objects
Plot method for fitted two mountains cv objects
1 2 3 4 5 6 7 |
x |
fitted "ordinis" model object or fitted "cv.ordinis" model object |
xvar |
What is on the X-axis. |
labsize |
size of labels for variable names. If labsize = 0, then no variable names will be plotted |
xlab |
label for x-axis |
ylab |
label for y-axis |
main |
main title for plot |
xlim |
numeric vectors of length 2, giving the |
n.print |
scalar integer for the number of times along the regularization path to print the number of nonzero coefficients. If set to a negative value, the number of nonzero coefficients will not be printed. |
... |
other graphical parameters for the plot |
sign.lambda |
Either plot against log(lambda) (default) or its negative if |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 | set.seed(123)
n.obs <- 100
n.vars <- 1000
true.beta <- c(runif(5, 0.1, 1) * (2 * rbinom(5, 1, 0.5) - 1), rep(0, n.vars - 5))
x <- matrix(rnorm(n.obs * n.vars), n.obs, n.vars)
y <- rnorm(n.obs, sd = 2) + x %*% true.beta
fit <- ordinis(x = x, y = y, penalty = c("mcp"))
plot(fit)
set.seed(123)
n.obs <- 100
n.vars <- 200
true.beta <- c(runif(15, -0.5, 0.5), rep(0, n.vars - 15))
x <- matrix(rnorm(n.obs * n.vars), n.obs, n.vars)
y <- rnorm(n.obs, sd = 3) + x %*% true.beta
fit <- cv.ordinis(x = x, y = y, gamma = 1.4)
plot(fit)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.