Skip to contents

This function plots the importance scores in test data, showing the Angle versus Intensity coloured by the feature importance derived from a RandomForest model, alongside a colour bar representing the importance score scale.

Usage

plotImportanceScores(
  res_tockyrf,
  percentile = 0.9,
  test = TRUE,
  plot_mode = "Angle",
  xlim = NULL,
  ylim = NULL
)

Arguments

res_tockyrf

A list object output from TockyKmeansRF.

percentile

Numeric, percentile threshold for importance scores (between 0 and 1).

test

Logical. If TRUE, Importance Score plot using test data used for creating the TockyKmeansRF model will be used. If FALSE, the training data will be used instead.

plot_mode

Either "raw_Timer" for Blue vs Red plots, or "Angle" for Angle vs Intensity plots.

xlim

Optional to determine the x ranges of plot. Effective for raw Timer plot only.

ylim

Optional to determine the y ranges of plot. Effective for raw Timer plot only.

Value

A plot of Angle vs Intensity coloured by importance and a colour bar indicating the importance scores.

Examples

if (FALSE) { # \dontrun{
  # Assuming 'res_tockyrf' is already available from using TockyKmeansRF
  plotImportanceScores(res_tockyrf)
} # }