[R] [OT] two question about color space.

Jinsong Zhao jszhao at mail.hzau.edu.cn
Sat Mar 14 14:41:32 CET 2009


> if you don't mind about the efficiency of your program, just use ?
> sapply on a range of wavelengths. I'm not particularly keen on the
> implementation of the FORTRAN program you used compared to the one I
> suggested, it seems like a very crude convolution.
>

Thank you very much for your suggestion, I will try to use ``sapply''.
As for the Fortran program, it's not as accuracy as the C program you
recommended, because it converts wavelength to RGB approximately.

>
> The easiest way I know of is using ggplot2, see the last example of
> this page:
>
> http://had.co.nz/ggplot2/geom_path.html
>
>
> In base graphics, you could use segments to join the observations and
> supply a vector of colours of appropriate length.
>
Thanks again for your suggestion, I will try.

Best regards,
Jinsong




More information about the R-help mailing list