Learn R Programming

MLwrap (version 0.1.0)

table_olden_results: Olden Results Table

Description

The table_olden_results() function extracts results from the Olden method, a technique specific to neural networks that calculates relative importance of input variables through analysis of connection weights between network layers. This method provides a measure of each variable's contribution based on the magnitude and direction of synaptic connections.

Usage

table_olden_results(analysis_object, show_table = FALSE)

Value

Tibble or list of tibbles (multiclass classification) with Olden results.

Arguments

analysis_object

Fitted analysis_object with 'sensitivity_analysis(methods = "Olden")'.

show_table

Boolean. Whether to show the table.

Examples

Run this code
# Note: For obtaining the table with Olden method results the user needs to complete till
# sensitivity_analysis() function of the MLwrap pipeline using the Olden method.
# Remember Olden method only can be used with neural network model.

if (requireNamespace("torch", quietly = TRUE)) {

  # \donttest{

  wrap_object <- preprocessing(df = sim_data,
                             formula = psych_well ~ depression + emot_intel + resilience,
                             task = "regression")
  wrap_object <- build_model(wrap_object, "Neural Network")
  wrap_object <- fine_tuning(wrap_object, "Bayesian Optimization")
  wrap_object <- sensitivity_analysis(wrap_object, methods = "Olden")

  # And then, you can obtain the Olden results table.

  table_Olden <- table_olden_results(wrap_object)

  # }

}

Run the code above in your browser using DataLab