Learn R Programming

colourvision (version 2.1.0)

colourvision-package: tools:::Rd_package_title("colourvision")

Description

tools:::Rd_package_description("colourvision")

Arguments

Author

tools:::Rd_package_author("colourvision")

Maintainer: tools:::Rd_package_maintainer("colourvision")

Details

The DESCRIPTION file: tools:::Rd_package_DESCRIPTION("colourvision") tools:::Rd_package_indices("colourvision")

References

Gawryszewski, F.M. 2018. Colour vision models: Some simulations, a general n-dimensional model, and the colourvision R package. Ecology and Evolution, 10.1002/ece3.4288.

Examples

Run this code
##Honeybee photoreceptor sensitivity curves
data("bee")

##Grey background:
## with 10 percent. reflectance from 300 to 700nm:
Rb <- data.frame(300:700, rep(10, length(300:700)))

## Read CIE D65 standard illuminant already converted to quantum flux:
data("D65")

##Reflectance data
## with a sigmoid spectrum and midpoint at 500nm and 550 nm
R1<-logistic(x=seq(300,700,1), x0=500, L=50, k=0.04)
R2<-logistic(x=seq(300,700,1), x0=550, L=50, k=0.04)
R<-cbind(R1, R2[,2])

## Run colour vision model:
model<-CTTKmodel(photo="tri", R=R, I=D65, Rb=Rb,
C=bee)

##plot data in the colour space
plot(model)

Run the code above in your browser using DataLab