Evaluates the model at the supplied values.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(mcmc_target), | intent(in) | :: | this |
The mcmc_target object. |
||
real(kind=real64), | intent(in), | dimension(:) | :: | xdata |
An M-element array containing the values at which to evaluate the model. |
|
real(kind=real64), | intent(in), | dimension(:) | :: | xc |
An N-element array containing the model parameters. |
|
real(kind=real64), | intent(out), | dimension(:) | :: | y |
An M-element array where the resulting model values wil be written. |
A type allowing for the construction of chain of values.
procedure , public :: get_chain => cb_get_chain Function | |
procedure , public :: get_chain_length => cb_get_chain_length Function | |
procedure , public :: get_state_variable_count => cb_get_nvars Function | |
procedure , public :: push_new_state => cb_push Subroutine | |
procedure , public :: reset => cb_clear_chain Subroutine |
Defines a type responsible for generating a proposal state for a Monte-Carlo, Markov-Chain sampler.
procedure , public :: generate_sample => mp_gen Subroutine | |
procedure , public :: get_recenter => mp_get_recenter Function | |
procedure , public :: set_recenter => mp_set_recenter Subroutine |
An implementation of the Metropolis-Hastings algorithm for the generation of a Markov chain.
procedure , public :: get_accepted_count => ms_get_num_accepted Function | |
procedure , public :: get_chain => cb_get_chain Function | |
procedure , public :: get_chain_length => cb_get_chain_length Function | |
procedure , public :: get_state_variable_count => cb_get_nvars Function | |
procedure , public :: on_acceptance => ms_on_success Subroutine | |
procedure , public :: on_rejection => ms_on_rejection Subroutine | |
procedure , public :: push_new_state => cb_push Subroutine | |
procedure , public :: reset => cb_clear_chain Subroutine | |
procedure , public :: sample => ms_sample Subroutine |
Defines a model of the target distribution(s). This type is key to the MCMC regression process. The approach taken is to evaluate the model provided here and evaluating its likelihood. The likelihood is evaluated by computing the residual between the model and data, and making the assumption that the residual should be normally distributed.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
real(kind=real64), | public | :: | data_noise | = | 1.0d0 |
A parameter representing the noise in the data. |
procedure , public :: add_parameter => mt_add_param Subroutine | |
procedure , public :: evaluate_prior => mt_eval_prior Function | |
procedure , public :: evaluate_variance_prior => mt_eval_var_prior Function | |
procedure , public :: get_parameter => mt_get_param Function | |
procedure , public :: get_parameter_count => mt_get_param_count Function | |
procedure , public :: likelihood => mt_likelihood Function | |
procedure (evaluate_model) , public :: model | |
procedure , public :: sample_variance_prior => mt_sample_var_prior Function |