hist.BranchGLMVI.boot: Histogram Method for BranchGLMVI.boot Objects

View source: R/VariableImportance.boot.R

hist.BranchGLMVI.bootR Documentation

Histogram Method for BranchGLMVI.boot Objects

Description

Creates histograms of approximate null distributions for the modified variable importance values.

Usage

## S3 method for class 'BranchGLMVI.boot'
hist(
  x,
  which = "all",
  linecol = "red",
  linelwd = 2,
  xlim = NULL,
  xlab = "Modified Variable Importance",
  main = NULL,
  ...
)

Arguments

x

a BranchGLMVI.boot object.

which

which approximate null distributions to plot, can use a numeric vector of indices, a character vector of names, or "all" for all variables. The default is to create histograms for each set of variables that are not kept in each model.

linecol

the color of the line which indicates the observed modified variable importance values.

linelwd

the width of the line which indicates the observed modified variable importance values.

xlim

a numeric vector of length 2, giving the x coordinates range.

xlab

a label for the x axis.

main

a main title for the plot.

...

further arguments passed to hist.default.

Value

This only produces a plot, nothing is returned.

See Also

boxplot.BranchGLMVI.boot

Examples

Data <- iris
Fit <- BranchGLM(Sepal.Length ~ ., data = Data, family = "gaussian", link = "identity")

# Doing branch and bound selection 
VS <- VariableSelection(Fit, type = "branch and bound", metric = "BIC", 
showprogress = FALSE)

# Getting approximate null distributions
set.seed(40174)
myBoot <- VariableImportance.boot(VS, showprogress = FALSE)

# Plotting histograms of second set of variables
hist(myBoot, which = 2)

# Plotting histograms of third set of variables
hist(myBoot, which = 3, linecol = "blue", linelwd = 5)


BranchGLM documentation built on Sept. 28, 2024, 9:07 a.m.