plsda_feature_importance_plot: PLSDA feature importance summary plot

View source: R/plsda_feature_significance_chart.R

plsda_feature_importance_plotR Documentation

PLSDA feature importance summary plot

Description

A plot of the selected feature significance metric for a PLSDA model for the top selected features.

Usage

plsda_feature_importance_plot(n_features = 30, metric = "vip", ...)

Arguments

n_features

(numeric, integer) The number of features to include in the summary. The default is 30.

metric

(character) Metric to plot. Allowed values are limited to the following:

  • "sr": Plot Selectivity Ratio.

  • "sr_pvalue": Plot SR p-values.

  • "vip": Plot Variable Importance in Projection scores.

The default is "vip".

...

Additional slots and values passed to struct_class.

Details

This object makes use of functionality from the following packages:

  • pls

  • ggplot2

  • reshape2

  • cowplot

Value

A plsda_feature_importance_plot object. This object has no output slots. See chart_plot in the struct package to plot this chart object.

Inheritance

A plsda_feature_importance_plot object inherits the following struct classes:

⁠[plsda_feature_importance_plot]⁠ >> ⁠[chart]⁠ >> ⁠[struct_class]⁠

References

Liland K, Mevik B, Wehrens R (2023). pls: Partial Least Squares and Principal Component Regression. R package version 2.8-3, https://CRAN.R-project.org/package=pls.

Wickham H (2016). ggplot2: Elegant Graphics for Data Analysis. Springer-Verlag New York. ISBN 978-3-319-24277-4, https://ggplot2.tidyverse.org.

Wickham H (2007). "Reshaping Data with the reshape Package." Journal of Statistical Software, 21(12), 1-20. http://www.jstatsoft.org/v21/i12/.

Wilke C (2024). cowplot: Streamlined Plot Theme and Plot Annotations for 'ggplot2'. R package version 1.1.3, https://CRAN.R-project.org/package=cowplot.

Examples

M = plsda_feature_importance_plot(
      n_features = 50,
      metric = "vip")

D = iris_DatasetExperiment()
M = mean_centre()+PLSDA(factor_name='Species')
M = model_apply(M,D)

C = plsda_feature_importance_plot(n_features=30,metric='vip')
chart_plot(C,M[2])

computational-metabolomics/structtoolbox documentation built on July 2, 2024, 10:46 p.m.