plot_graph_nn: Plot Neural Network Architecture

View source: R/plotting_utils.R

plot_graph_nnR Documentation

Plot Neural Network Architecture

Description

Plots a graph visualization of the Neural Network's architecture along with its optimized hyperparameters.

Usage

plot_graph_nn(analysis_object)

Arguments

analysis_object

Fitted analysis_object with 'fine_tuning()'.

Value

analysis_object

Examples

# Note: For obtaining the Neural Network architecture graph plot the user needs to
# complete till the fine_tuning( ) function of the MLwrap pipeline.

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

  

  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")

  # And then, you can obtain the Neural Network architecture graph plot.

  plot_graph_nn(wrap_object)

  

}


MLwrap documentation built on Aug. 8, 2025, 6:43 p.m.