plotCS: Plot Collapsed Cross-sections by 'Gap Width' or 'Proportion...

View source: R/plotCS.R

plotCSR Documentation

Plot Collapsed Cross-sections by 'Gap Width' or 'Proportion Missing'

Description

Function to generate collapsed cross-section plots to visualize changes in the performance metrics of interest as the proportion of missing data and gap width increase. Instead of three axes, as in the surface plots, either p or g can be 'collapsed' such that changes in performance are depicted with respect to one variable, across all values of the other. This variable is specified in cross_section, and will form the x-axis of the cross-section plot.

  • The middle line is the median value of the collapsed variable

  • The upper ribbon boundary is the maximum value

  • The lower ribbon boundary is the minimum value

Usage

plotCS(
  d = 1:length(agEval),
  m = names(agEval[[1]][[1]][[1]]),
  crit,
  agEval,
  layer_type = "method",
  f = "median",
  cross_section = "p",
  highlight = NULL,
  highlight_color = "#FF0000",
  colors = c("#FF8633", "#FFAF33", "#FFD133", "#FFEC33", "#D7FF33", "#96FF33")
)

Arguments

d

numeric; A vector to indicate datasets of interest

m

character; A vector of interpolation methods of interest

crit

character; An element describing the performance metric of interest

agEval

agEvaluate; An object containing the aggregated performance metrics (result of agEvaluate())

layer_type

character; How to layer the ribbons (by "method" or by "dataset")

f

character; The statistic of interest defining the ribbon. Possible choices are listed in ?agEvaluate

cross_section

character; An element describing the gap structure variable to represent on the x-axis: either "p" or "g"

highlight

character/numeric; A single method (if layer_type = "method") or dataset (if layer_type = "dataset") to highlight.

highlight_color

character; An HTML color of format "#xxxxxx" to apply to highlight

colors

character; A vector of the desired color palette, with entries in HTML format ("#xxxxxx")


castels/interpTools documentation built on June 7, 2024, 4:20 p.m.