plot.L0Learn {L0Learn}R Documentation

Plot Regularization Path

Description

Plots the regularization path for a given gamma.

Usage

## S3 method for class 'L0Learn'
plot(x, gamma = 0, showLines = FALSE, ...)

Arguments

x

The output of L0Learn.fit

gamma

The value of gamma at which to plot.

showLines

If TRUE, the lines connecting the points in the plot are shown.

...

ignore

Value

A ggplot object.

Examples

# Generate synthetic data for this example
data <- GenSynthetic(n=100,p=20,k=10,seed=1)
X = data$X
y = data$y
# Fit an L0 Model
fit <- L0Learn.fit(X, y, penalty="L0")
plot(fit, gamma=0)


[Package L0Learn version 2.1.0 Index]