[R] colors, lines, characters .... documentation
kjetil@entelnet.bo
kjetil at entelnet.bo
Thu Mar 25 02:39:54 CET 2004
On 24 Mar 2004 at 15:05, Monica Palaseanu-Lovejoy wrote:
> Hi,
>
> Very so often when i am plotting something, doing a histogram, or
> whatever i am struggling to find out which are the numbers for
> different colors, palette names, types of lines, symbols, etc. Is
> there any documentation on line with all these numbers / names and the
> associated symbol / color???
>
I do usually something like:
plot(1:20, rep(1,20), pch=1:20, col=1:20)
plot(1:20, 1:20, type="n")
for (i in 1:20) {
+ lines( c(1,20), c(i,i), lty=i) }
> For example if i am using the command image it uses a palette
> from red to yellow, with red the lowest value, and yellow the highest
> value. What if i want a reverse palette, with green the lowest value
:
palette(rev(palette()))
palette()
[1] "gray" "yellow" "magenta" "cyan" "blue" "green3" "red"
[8] "black"
> and yellow middle values and red highest value??? Or much more simple,
> just yellow lowest value and red highest value???
See also the CRAN package RColorBrewer
Kjetil Halvorsen
>
> Thank you for assistance,
>
> Monica
>
> ______________________________________________
> R-help at stat.math.ethz.ch mailing list
> https://www.stat.math.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide!
> http://www.R-project.org/posting-guide.html
More information about the R-help
mailing list