powered by
legend
Plot legend - shortcut to the legend function
rtsplot.legend( labels, fill = NULL, lastobs = NULL, x = "topleft", merge = FALSE, bty = "n", border = NA, yformat = rtsplot.format, cex = 1, ... )
nothing
legend labels
fill colors, defaults to NULL
list of last observations, defaults to NULL
location of legend, defaults to 'topleft'
merge, defaults to FALSE, see legend function for more info
box, defaults to 'n', see legend function for more info
border color, defaults to NA - no color
format Y values function, defaults to rtsplot.format
rtsplot.format
font size, defaults to 1
other parameters to legend, see legend function for more info
y = rtsplot.fake.stock.data(1000) symbol = 'SPY' # plot layout(1) rtsplot(y, type = 'l', col='black') rtsplot.legend(symbol, 'black', y)
Run the code above in your browser using DataLab