# color examples
par(mfrow=c(2,3), bg='wheat')
times <- c(1,100,200,300,400,500,600)
f3lc <- longCat( example3, times, Labels=rep('',5) )
longCatPlot(f3lc, main='colScheme=gray', colScheme='gray',
lwd=.1, ylab='', legendBuffer = .25)
longCatPlot(f3lc, main='colScheme=rainbow', colScheme='rainbow',
lwd=.1, ylab='', legendBuffer = .25)
longCatPlot(f3lc, main='colScheme=heat', colScheme='heat',
lwd=.1, ylab='', legendBuffer = .25)
longCatPlot(f3lc, main='colScheme=terrain', colScheme='terrain',
lwd=.1, ylab='', legendBuffer = .25)
longCatPlot(f3lc, main='colScheme=topo', colScheme='topo',
lwd=.1, ylab='', legendBuffer = .25)
longCatPlot(f3lc, main='colScheme=cm', colScheme='cm',
lwd=.1, ylab='', legendBuffer = .25)
par(mfrow=c(1,1), bg='transparent')
## Not run: ------------------------------------
# # illustrate the use of colors from the package RColorBrewer
# library(RColorBrewer)
# par(mfrow=c(2,3), bg='cornsilk3')
# longCatPlot(f3lc, main='RColorBrewer: Blues', cols=brewer.pal(f3lc$nfactors, "Blues"),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='RColorBrewer: Greens', cols=brewer.pal(f3lc$nfactors, "Greens"),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='RColorBrewer: PuBuGn', cols=brewer.pal(f3lc$nfactors, "PuBuGn"),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='RColorBrewer: YlOrRd', cols=brewer.pal(f3lc$nfactors, "YlOrRd"),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='RColorBrewer: Spectral', cols=brewer.pal(f3lc$nfactors, "Spectral"),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='RColorBrewer: Accent', cols=brewer.pal(f3lc$nfactors, "Accent"),
# lwd=.1, ylab='', legendBuffer = .25)
# par(mfrow=c(1,1), bg='transparent')
#
# # illustrate the use of colors from the package colorspace
# library(colorspace)
# par(mfrow=c(2,3), bg='cornsilk3')
# longCatPlot(f3lc, main='colorspace: rainbow_hcl', cols=rainbow_hcl(f3lc$nfactors),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='colorspace: sequential_hcl', cols=sequential_hcl(f3lc$nfactors),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='colorspace: heat_hcl', cols=heat_hcl(f3lc$nfactors),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='colorspace: terrain_hcl', cols=terrain_hcl(f3lc$nfactors),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='colorspace: diverge_hcl', cols=diverge_hcl(f3lc$nfactors),
# lwd=.1, ylab='', legendBuffer = .25)
# longCatPlot(f3lc, main='colorspace: diverge_hsv', cols=diverge_hsv(f3lc$nfactors),
# lwd=.1, ylab='', legendBuffer = .25)
# par(mfrow=c(1,1), bg='transparent')
## ---------------------------------------------
Run the code above in your browser using DataLab