fn_switch: Function switch

Description Usage Arguments Examples

View source: R/ggnostic.R

Description

Function that allows you to call different functions based upon an aesthetic variable value.

Usage

1
fn_switch(types, mapping_val = "y")

Arguments

types

list of functions that follow the ggmatrix function standard: function(data, mapping, ...){ #make ggplot2 object }. One key should be a 'default' key for a default switch case.

mapping_val

mapping value to switch on. Defaults to the 'y' variable of the aesthetics list.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21

GGally documentation built on June 8, 2017, 9:03 a.m.

Search within the GGally package
Search all R packages, documentation and source code