hzar.make.clineLLfunc.old.ML: Generate a Log Likelihood method for the cline model.

Description Usage Arguments Value Author(s) See Also Examples

View source: R/31-hzarFittingNew.R

Description

A low-level method for assembling a cline likelihood method. See hzar.first.fitRequest.old.ML for an easier to use method for working with clines.

Using the arguments given, assemble either a maximum likelihood (ML) or bayesian (bayes) function with a single argument theta. The result is suitable for MCMCmetrop1R.

Usage

1
2
3
4
5
hzar.make.clineLLfunc.old.ML(param.free.names, param.fixed,
  param.check.func, meta.cline.func, model.LL, LLrejectedModel = -1e+08) 
hzar.make.clineLLfunc.old.bayes(param.free.names, param.fixed,
  param.check.func, meta.cline.func, model.LL, prior.LL,
  LLrejectedModel = -1e+08) 

Arguments

param.free.names

The names of the free parameters.

param.fixed

A named list of the fixed parameters.

param.check.func

A boolean function of the parameters, which returns true if the model described is valid.

meta.cline.func

A function of the parameters, which returns a function of distance estimating frequency.

model.LL

A function which takes one argument and returns a log likelihood. The argument is a function of distance estimating frequency.

LLrejectedModel

A finite log likelihood of an invalid model.

prior.LL

A function of the parameters, which returns the log likelihood of those parameters.

Value

A function with a single argument theta that returns a finite log likelihood.

Theta is a named list of the free parameters for a cline.

Author(s)

Graham Derryberry asterion@alum.mit.edu

See Also

MCMCmetrop1R hzar.first.fitRequest.old.ML

Examples

1
##TODO

Example output

Loading required package: MCMCpack
Loading required package: coda
Loading required package: MASS
##
## Markov Chain Monte Carlo Package (MCMCpack)
## Copyright (C) 2003-2019 Andrew D. Martin, Kevin M. Quinn, and Jong Hee Park
##
## Support provided by the U.S. National Science Foundation
## (Grants SES-0350646 and SES-0350613)
##
Loading required package: foreach

hzar documentation built on May 2, 2019, 7 a.m.