Skip to contents

This is a base class designed to handle the learning of the underlying coefficients, hyperparameters, and parameters associated with a specific learning instance. Polymorphism allows for the implied methods to be used across several similar classes.

Value

no returns, this is a class which contains methods

Fields

lpdf$val

current value

lpdf$para

current model parameters

lpdf$coeff

current coefficients

lpdf$compute_val

on calling update, compute value and store in val

lpdf$grad

current gradient with respect to coefficients

lpdf$gradhyp

current gradient with respect to covariance hyperparameters

lpdf$gradpara

current gradient with respect to model parameters

lpdf$compute_grad

on calling update, compute gradient with respect to coefficients and store in grad

lpdf$compute_gradhyp

on calling update, compute gradient with respect to covariance hyperparameters and store in gradhyp

lpdf$compute_gradpara

on calling update, compute gradient with respect to model parameters and store in gradpara

lpdf$update(coeff)

update using new coefficients

lpdf$optcg(tol,epoch)

do optimization with respect to coefficients via conjugate gradient

lpdf$optnewton()

do optimization via matrix inversion, one Newton step

lpdf$updateom()

update based on recent version of outermod

lpdf$updatepara(para)

update using new model parameters

lpdf$updateterms(terms)

update using new terms

lpdf$hess()

returns the hessian with respect to coefficients

lpdf$hessgradhyp()

returns gradient of hess() with respect to covariance hyperparameters

lpdf$hessgradpara()

returns the gradient of hess() with respect to model parameters

lpdf$diaghess()

returns the diagonal of the hessian with respect to coefficients

lpdf$diaghessgradhyp()

returns the gradient of diaghess() with respect to covariance hyperparameters

lpdf$diaghessgradpara()

returns the gradient of diaghess() with respect to model parameters

lpdf$paralpdf(para)

compute the log-prior on the parameters, useful for fitting

lpdf$paralpdf_grad(para)

gradient of paralpdf(para)

See also

container class: lpdfvec

derived classes: loglik_std, loglik_gauss, loglik_gda, logpr_gauss