sim.gradient: Simulate an environmental gradient

View source: R/sim.trait.values.R

sim.gradientR Documentation

Simulate an environmental gradient

Description

Function returns a vector using the sine wave function y = depth*sin(cycles*pi*(x-1/4)) for a given set of intervals. This vector can be used as a gradient to simulate fossils under an environment-dependent model of fossil recovery using the function sim.fossils.environment.

Usage

sim.gradient(strata, depth = 2, cycles = 2)

Arguments

strata

Number of stratigraphic intervals.

depth

Maximum water depth.

cycles

Number of cycles (e.g. transgressions and regressions).

Value

vector of sampled water depths.

See Also

sim.fossils.environment

Examples

strata = 100
wd = sim.gradient(strata)
plot(wd, type="l")

fossilsim/fossilsim documentation built on April 23, 2024, 3:16 p.m.