if (FALSE) {
yellow.colors <- function(n) { hsv(h=0.15, v=0:(n-1)/(n-1)) }
df <- ds[[1]]
writeImage(df, tags="gray", palette=gray.colors(256), xrange=c(0,200))
writeImage(df, tags="yellow", palette=yellow.colors(256), xrange=c(0,200))
writeImage(df, tags="heat", palette=heat.colors(256), xrange=c(0,200))
writeImage(df, tags="terrain", palette=terrain.colors(256), xrange=c(0,200))
writeImage(df, tags="topo", palette=topo.colors(256), xrange=c(0,200))
writeImage(df, tags="cm", palette=cm.colors(256), xrange=c(0,200))
writeImage(df, tags="rainbow", palette=rainbow(256), xrange=c(0,200))
}
Run the code above in your browser using DataLab