lm.s: Estimate s with LLS

Description Usage Arguments Details Value Author(s) References See Also

View source: R/estsh.R

Description

lm.s estimates s with linear least squares regression.

Usage

1
lm.s(ctraj, haploid, maxiter = 10, tol = 0.01)

Arguments

ctraj

a consensus trajectory as returned by consensus.traj.

haploid

logical indicating wether a population of haploid (haploid = TRUE) or diploid (default) individuals should be simulated.

maxiter

integer defining the maximum number of iterations to correct for discrepancies between a selection model with discrete or overlapping generations.

tol

numeric specifying the tolerance for the iterative bias correction. If tol = 0.01, then the correction procedure will stop once the deviation between the discrete and continuouse model is less than 1%.

Details

Instead of calling this function directly, use estimateSH instead.

Value

A named numeric vector with estimates of both s and p0 is returned.

Author(s)

Thomas Taus

References

Taus T., Futschik A. and Schlötterer C., manuscript in preparation.

See Also

estimateSH and nls.sh


ThomasTaus/poolSeq documentation built on Oct. 22, 2018, 7:21 p.m.