View source: R/Tagloss_mcmc_p.R
Tagloss_mcmc_p | R Documentation |
Interactive (or not!) script used to generate set of parameters to be used with Tagloss_mcmc().
Tagloss_mcmc_p(
result = stop("An output from Tagloss_fit() must be provided"),
default.density = "dunif",
accept = FALSE
)
result |
An object obtained after a Tagloss_fit() fit |
default.density |
The default density, "dnorm" or "dunif' |
accept |
If TRUE, does not wait for use interaction |
Tagloss_mcmc_p generates set of parameters to be used with Tagloss_mcmc()
A matrix with the parameters
Marc Girondot
Other Model of Tag-loss:
Tagloss_L()
,
Tagloss_LengthObs()
,
Tagloss_cumul()
,
Tagloss_daymax()
,
Tagloss_fit()
,
Tagloss_format()
,
Tagloss_mcmc()
,
Tagloss_model()
,
Tagloss_simulate()
,
logLik.Tagloss()
,
o_4p_p1p2
,
plot.Tagloss()
,
plot.TaglossData()
## Not run:
library(phenology)
# Example
data_f_21 <- Tagloss_format(outLR, model="21")
# model fitted by Rivalan et al. 2005
par <- c(a0_2=-5.43E-2, a1_2=-103.52, a4_2=5.62E-4,
delta_1=3.2E-4)
pfixed <- c(a2_2=0, a3_2=0, a2_1=0, a3_1=0)
model_before <- "par['a0_1']=par['a0_2'];par['a1_1']=par['a1_2'];par['a4_1']=par['a4_2']"
o <- Tagloss_fit(data=data_f_21, fitted.parameters=par, fixed.parameters=pfixed,
model_before=model_before)
pMCMC <- Tagloss_mcmc_p(o, accept=TRUE)
o_MCMC <- Tagloss_mcmc(data=data_f_21, parameters=pMCMC, fixed.parameters=pfixed,
model_before=model_before,
n.iter=10000, n.chains = 1, n.adapt = 100, thin=30)
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.