convertLabelToExpr: Convert plot with newline characters to plotmath

Description Usage Arguments Details Value

Description

Function to convert plot with newline characters to plotmath

Usage

1

Arguments

txt

- character vector of labels.

test

- flag to plot labels (for debugging)

Details

Converts the vector of labels to a text vector which can be parsed to yield a plotmath expression. Each label is first split by newline characters. The first split is re-split using ":". The last line is split by "R^2". The resulting splits are recombined in nested 'atop(x,y)' functions (see plotmath), with the first re-split interpreted as a plotmath expression, as is 'R^2'.

test=TRUE requires ggplot2 package.

Value

character vector of labels


wStockhausen/wtsDisMELSConn documentation built on May 3, 2019, 7:36 p.m.