sraMinuslogL: Calculation of the likelihood of time series (internal...

sraMinuslogLR Documentation

Calculation of the likelihood of time series (internal functions)

Description

These functions are used internally by the sra package to compute the likelihood of the dataset given a specific model.

Usage

sraMinuslogL(sradata, FUNtimeseries = sraAutoregTimeseries, 
	Bulmer=TRUE, logvarME=log(1e-20), ...)
sraMinuslogL.log(sradata.log, FUNtimeseries = sraAutoregTimeseries, 
	Bulmer=TRUE, logvarME=log(1e-20), ...)
sraAutoregTsMinuslogL(data.mean, data.var, data.N, 
	theor.mean, theor.var, logvarME=log(1e-20))
sraAutoregTsMinuslogL.log(data.mean, data.var, data.N, 
	theor.mean, theor.var, logvarME=log(1e-20))

Arguments

sradata

A data object generated by sraData.

sradata.log

A data object generated by sraData after log transformation.

FUNtimeseries

The corresponding function to compute the expected time series (one of those listed in sraAutoregTimeseries.

Bulmer

Whether or not the impact of linkage disequilibrium (Bulmer effect) due to selection on variance should be accounted for.

logvarME

(log)-macroenvironmental variance, which is not included in the models themself (no impact on the expected time series), but can be estimated through its effect on the residual variance.

...

The parameters of the model.

data.mean

The vector of the mean phenotypes, from the data.

data.var

The vector of the phenotypic variances, from the data.

data.N

The vector of the population sizes, from the data.

theor.mean

The vector of the theoretical mean phenotypes, from the model.

theor.var

The vector of the theoretical phenotypic variances, from the model.

Value

sraAutoregTsMinuslogL returns the minus log likelihood of a single time series (e.g. one selection line). sraMinuslogL returns the minus log likelihood of the whole dataset, including all repetitions. The ".log" version of these functions compute the likelihood when sradata has been log-transformed.

Note

These functions are not designed to be called by the end user.

References

Le Rouzic, A., Houle, D., and Hansen, T.F. (2011) A modelling framework for the analysis of artificial selection-response time series. Genetics Research.

See Also

sraAutoreg, sraCstvar, and all other mechanistic models, sraAutoregTimeseries.


sra documentation built on March 31, 2023, 9:31 p.m.