plot.gmu_lasso: Plot the estimates returned by gmu_lasso

View source: R/plot.gmu_lasso.R

plot.gmu_lassoR Documentation

Plot the estimates returned by gmu_lasso

Description

Plot the number of nonzero coefficients along a range of delta values if delta has length larger than 1, or the estimated coefficients of delta has length 1.

Usage

## S3 method for class 'gmu_lasso'
plot(x, ...)

Arguments

x

An object of class gmu_lasso

...

Other arguments to plot (not used).

Examples

set.seed(1)
n <- 200
p <- 50
s <- 10
beta <- c(rep(1,s),rep(0,p-s))
sdU <- 0.2

X <- matrix(rnorm(n*p),nrow = n,ncol = p)
W <- X + sdU * matrix(rnorm(n * p), nrow = n, ncol = p)

y <- rbinom(n, 1, (1 + exp(-X%*%beta))**(-1))
gmu_lasso <- gmu_lasso(W, y)

plot(gmu_lasso)


osorensen/hdme documentation built on May 18, 2023, 11:35 p.m.