plot.fit_t.env: Plot the phenotypic evolutionary rate through time estimated...

Description Usage Arguments Value Note Author(s) References See Also Examples

View source: R/plot.fit_t.env.r

Description

Plot estimated evolutionary rate as a function of the environmental data and time.

Usage

1
2
## S3 method for class 'fit_t.env'
plot(x, steps = 100, ...)

Arguments

x

an object of class 'fit_t.env' obtained from a fit_t_env fit.

steps

the number of steps from the root to the present used to compute the evolutionary rate σ2 through time.

...

further arguments to be passed to plot. See ?plot.

Value

plot.fit_t.env returns invisibly a list with the following components used in the current plot:

time_steps

the times steps where the climatic function was evaluated to compute the rate. The number of steps is controlled through the argument steps.

rates

the estimated evolutionary rate through time estimated at each time_steps

Note

All the graphical parameters (see par) can be passed through (e.g. line type: lty, line width: lwd, color: col ...)

Author(s)

J. Clavel

References

Clavel, J. & Morlon, H., 2017. Accelerated body size evolution during cold climatic periods in the Cenozoic. Proceedings of the National Academy of Science, 114(16): 4183-4188.

See Also

lines.fit_t.env, likelihood_t_env

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
data(Cetacea)
data(InfTemp)

# Simulate a trait with temperature dependence on the Cetacean tree
set.seed(123)


trait <- sim_t_env(Cetacea, param=c(0.1,0.2), env_data=InfTemp, model="EnvExp", 
					root.value=0, step=0.01, plot=TRUE)


## Fit the Environmental-exponential model

result1=fit_t_env(Cetacea, trait, env_data=InfTemp, scale=TRUE)
plot(result1)

# further options
plot(result1, lty=2, lwd=2, col="red")

RPANDA documentation built on Aug. 7, 2018, 9:04 a.m.