tests/testthat/example_script.R

## This is just an example script; it makes use of 'dat' which is in
## the data.
blues <- c("#F7FBFF", "#DEEBF7", "#C6DBEF", "#9ECAE1", "#6BAED6",
           "#4292C6", "#2171B5", "#08519C", "#08306B")
things <- unique(dat$thing)
cols <- setNames(colorRampPalette(blues)(length(things)), things)
png("mygraph.png", width = 800, height = 600)
plot(value ~ number, dat, col = cols[thing], pch = 19, las = 1)
dev.off()

Try the orderly package in your browser

Any scripts or data that you put into this service are public.

orderly documentation built on Sept. 22, 2021, 5:09 p.m.