vote_update: Extract and adjust voting from SMLE selection

View source: R/vote.R

vote_updateR Documentation

Extract and adjust voting from SMLE selection

Description

When smle_select() is used with criterion = "ebic" and vote = TRUE, users can use vote_update() to adjust the voting threshold without a need of rerun smle_select().

Usage

vote_update(object, ...)

## S3 method for class 'selection'
vote_update(object, vote_threshold = 0.6, ...)

Arguments

object

A 'selection' object as the output from smle_select().

...

This argument is not used and listed for method consistency.

vote_threshold

A voting threshold in percentage. A feature is considered to be important when it receives votes passing the threshold. Default is 0.6.

Value

The function returns a vector indicating the features selected by EBIC voting with the specified vote_threhold.

Examples

set.seed(1)
Data <- Gen_Data(n = 100, p = 3000, correlation = "MA", rho = 0.7, family = "gaussian")
colnames(Data$X)<- paste("X.",seq(3000) , sep = "")
fit <- SMLE(Y = Data$Y, X = Data$X, k = 20, family = "gaussian")
fit_s <- smle_select(fit, criterion = "ebic", vote = TRUE)
plot(fit_s)
fit_s
vote_update(fit_s, vote_threshold = 0.4)

SMLE documentation built on Jan. 22, 2023, 1:55 a.m.