siarsolomcmc {siar}R Documentation

MCMC for stable isotope data with only single target organisms

Description

Runs an MCMC on stable isotope data from certain organisms to determine their dietary habits. This version requires only a single target organism per group

Usage

siarsolomcmc(data, sources, corrections = 0, iterations=200000, burnin=50000, howmany=10000, thinby=15, prior = rep(1, nrow(sources)), siardata=list(SHOULDRUN=FALSE))

Arguments

data A matrix with each food source as a seperate row and each isotope as a seperate column.
sources A matrix containing the mean and standard deviations of the fractionated correction values for each of the isotopes. Also allows corrections = 0 for pre-corrected data.
corrections A matrix containing the mean and standard deviations of the fractional correction values for each of the isotopes. Also allows corrections = 0 for pre-corrected data.
iterations The number of iterations to run.
burnin The size of the burnin
howmany How often to report the number of iterations.
thinby The amount of thinning of the iterations.
prior The dirichlet distribution prior parameters, the default is rep(1,numsources). New parameters can be estimated via the function siarelicit.
siardata A list containing some or all of the following parts: targets, sources, corrections, PATH, TITLE, numgroups, numdata, numsources, numiso, SHOULDRUN, GRAPHSONLY, EXIT, and output. For more details of these inputs see the siarmenu function.

Details

The model assumes that each target value comes from a Gaussian distribution with an unknown mean and standard deviation. The structure of the mean is a weighted combination of the food sources' isotopic values. The proportional weights are of key interest and are given a Dirichlet prior distribution. The standard deviation is divided up between the uncertainty around the fractionation corrections (if corrections are given) and the natural variability between target individuals within a defined group (or between all individuals if no grouping structure is specified). The default iterations numbers work well for the demo data sets, but advanced users will want to adjust them to suit their analysis.

Note that this version is analagous to the Moore and Semmens (2008) MixSIR model except with a Dirichlet prior distribution.

Value

A parameter matrix consisting of (iterations-burnin)/thinby rows with numgroups*(numsources+numiso) columns, where numsources is the number of food sources, numiso is the number of isotopes, and numgroups is the number of groups. The parameter matrix is structured so that, for each group, the first columns are those of the proportions of each food source eaten, the next columns are the standard deviations for each isotope. This format repeats across rows to each group. The parameters may then subsequently be used for plotting, convergence checks, summaries, etc, etc.

Note

Author(s)

Andrew Parnell

References

Moore and Semmens (2008), Incorporating uncertainty and prior information into stable isotope mixing models, Ecology Letters.

See Also

siarmenu, siarelicit

Examples






[Package siar version 3.2 Index]