plotStability {modnets}R Documentation

Plot stability selection paths for a given outcome

Description

Creates a plot to show the stability path for a particular variable in terms of how frequently it was chosen in stability selection.

Usage

plotStability(
  x,
  outcome = 1,
  s = c("simult", "split1", "split2"),
  thresh = 0.5,
  typeLegend = TRUE
)

Arguments

x

Output of resample where sampMethod = "stability".

outcome

Character string or numeric value (in terms of columns in the dataset) to indicate which outcome to plot the stability path for.

s

Character string or numeric value. This indicates which stability path to return a plot for. Either the first sample split "split1", the second sample split "split2", or the path for simultaneous selection "simult", which is the default.

thresh

The selection threshold, which is represented as a horizontal red line on the plot. Defaults to .5

typeLegend

Logical. If FALSE, linetype legend is removed. Only applies if there is a moderator in the model.

Details

See Meinshausen & Buhlmann (2010) for details on stability selection. Cannot be used when the criterion for stability selection was set as cross-validation.

Value

Plot of the stability path associated with a given outcome.

References

Meinshausen, N., & Buhlmann, P. (2010). Stability selection. Journal of the Royal Statistical Society: Series B (Statistical Methodology). 72, 417-423

See Also

resample

Examples


x <- resample(ggmDat, sampMethod = "stability")
plot(x, what = "stability")
plot(x, 'stability', outcome = 'V3')


[Package modnets version 0.9.0 Index]