pr_fit_parameters: Fit parameters of a phenology model to validation data

View source: R/pr_fit_parameters.R

pr_fit_parametersR Documentation

Fit parameters of a phenology model to validation data

Description

Calculates the estimated phenophases for a given set of parameters and a specified model (be sure to match parameter and requirements with the model.

Usage

pr_fit_parameters(
  par = NULL,
  data,
  cost = rmse,
  model = "TT",
  method = "GenSA",
  lower,
  upper,
  control,
  ...
)

Arguments

par

a vector of starting parameter values (function specific)

data

nested data structure with validation data as returned by format_phenocam() or format_pep725(), or your own dataset adhering to the same data structure.

cost

the cost function to use in the optimization, it should return a RMSE or other value which needs to be minimized

model

the model name to be used in optimizing the model

method

optimization method to use (default = GenSA) - GenSA : Generalized Simulated Annealing algorithm - genoud : GENetic Optimization Using Derivatives - BayesianTools: various bayesian based optimization tools

lower

lower limit of parameter values (function specific)

upper

upper limit of parameter values (function specific)

control

optimization control parameters (default = NULL)

...

extra arguments to pass to the function, mostly BayesianTools

Examples


## Not run: 
estimate <- pr_fit_parameters(par,data,model)

# estimate will return the best estimated parameter set given the
# validation data

## End(Not run)

khufkens/phenor documentation built on Aug. 31, 2023, 1:24 a.m.