Learn R Programming

Correlplot (version 1.1.0)

lincos: Linearized cosine function

Description

Function lincos linearizes the cosine function over the interval [0,2pi]. The function returns -2/pi*x + 1 over [0,pi] and 2/pi*x - 3 over [pi,2pi]

Usage

lincos(x)

Value

a real number in [-1,1].

Arguments

x

angle in radians

Author

Jan Graffelman (jan.graffelman@upc.edu)

References

Graffelman, J. (2012) Linear-angle correlation plots: new graphs for revealing correlation structure. Journal of Computational and Graphical Statistics. 22(1): 92-106.

See Also

Examples

Run this code
angle <- pi
y <- lincos(angle)
print(y)

Run the code above in your browser using DataLab