sievetest (version 1.2.3)

rrx2x: Sieve Test Data Object Plot Coordinates Transformation Functions

Description

Function transform user coordinates of plot to axis coordinates or vise versa.

Usage

rrx2x(x)
rry2y(x)
x2rrx(x)
y2rry(x)

Arguments

x

Value to transform.

Value

Functions return appropriate transformed value.

Details

The default plot type "rr" uses transformed coordinates, so the user can read percents on y axis and micrometers on x axis, while par('usr') returns coordinates in log(x) and log(log(100/y)). Hence the user can use transformation functions to convert between the types. The "rr" keyword in the name of function, belongs to the log x log-log (usr) space.

See Also

plot.std

Examples

Run this code
# NOT RUN {
data(lignite)
plot(lignite)
# query for exact x coordinates within the plot
if(interactive()) rrx2x(locator()$x)
# query for exact y coordinates within the plot
if(interactive()) rry2y(locator()$y)
# or 
y2rry(36.78794)
# or
rrx2x(par('usr')[1])
# }

Run the code above in your browser using DataCamp Workspace