colour.palettes: Model palettes

Colour palettesR Documentation

Model palettes

Description

These palettes can be passed to the plotting functions to change the model colours. By passing in the all.model.names it is possible to ensure that the model colours are consistent when plotting subsets of the full model set. You can even write your own function.

Usage

default.model.colours(
  selected.model.names,
  all.model.names = selected.model.names
)

colourblind.model.colours(
  selected.model.names,
  all.model.names = selected.model.names
)

rainbow.model.colours(
  selected.model.names,
  all.model.names = selected.model.names
)

groovy.model.colours(
  selected.model.names,
  all.model.names = selected.model.names,
  axis = "A"
)

Arguments

selected.model.names

A character vector of the subset of model names you want to plot.

all.model.names

A character vector of the all model names

Value

A named vector of colours, the same length and names as the models to be plotted.

Examples

all.model.names <- c("a","b","c","d")
# If you don't supply all.model.names, the colours for the models will not be consistent
default.model.colours(selected.model.names=all.model.names[1:2])
default.model.colours(selected.model.names=all.model.names[3:4])
# Colours for the models should not change when subsetting
# Supply all.model.names to make consistent
default.model.colours(selected.model.names=all.model.names, all.model.names=all.model.names)
default.model.colours(selected.model.names=all.model.names[1:2], all.model.names=all.model.names)
default.model.colours(selected.model.names=all.model.names[3:4], all.model.names=all.model.names)

PacificCommunity/ofp-sam-diags4MFCL documentation built on Nov. 7, 2022, 11:21 p.m.