75 void setPrior(
string priorType,
double priora,
double priorb);
1D Array class for any type T
2D Array class for any type T
Stores data of any type T in a 1D array.
Definition Array1D.h:61
Stores data of any type T in a 2D array.
Definition Array2D.h:60
Derived class for ABC likelihood.
Definition post.h:258
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:623
Lik_ABC(double eps)
Constructor given ABC epsilon.
Definition post.h:261
~Lik_ABC()
Destructor.
Definition post.h:263
double abceps_
ABC epsilon.
Definition post.h:270
Derived class for ABC-mean likelihood.
Definition post.h:278
~Lik_ABCm()
Destructor.
Definition post.h:283
Lik_ABCm(double eps)
Constructor given ABC epsilon.
Definition post.h:281
double abceps_
ABC epsilon.
Definition post.h:290
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:662
Derived class for classical likelihood.
Definition post.h:316
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:741
Lik_Classical()
Constructor.
Definition post.h:319
~Lik_Classical()
Destructor.
Definition post.h:321
Derived class for error-in-variable likelihood.
Definition post.h:332
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:774
Lik_Eov()
Constructor.
Definition post.h:335
~Lik_Eov()
Destructor.
Definition post.h:337
Derived class for full likelihood.
Definition post.h:159
~Lik_Full()
Destructor.
Definition post.h:164
double bdw_
KDE bandwidth.
Definition post.h:171
int nsam_
KDE sample size.
Definition post.h:173
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:437
Lik_Full(double bdw, int nsam)
Constructor given KDE bandwidth and sample size.
Definition post.h:162
Derived class for gaussian-marginal likelihood with discrete parameter.
Definition post.h:242
~Lik_GausMargD()
Destructor.
Definition post.h:247
Lik_GausMargD()
Constructor.
Definition post.h:245
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Derived class for gaussian-marginal likelihood.
Definition post.h:226
Lik_GausMarg()
Constructor.
Definition post.h:229
~Lik_GausMarg()
Destructor.
Definition post.h:231
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:589
Derived class for Kennedy-O'Hagan likelihood.
Definition post.h:298
Lik_Koh(double corLength)
Constructor given correlation length.
Definition post.h:301
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:694
double corLength_
Definition post.h:308
~Lik_Koh()
Destructor.
Definition post.h:303
Derived class for mvn likelihood.
Definition post.h:206
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:556
double nugget_
Nugget size.
Definition post.h:218
~Lik_MVN()
Destructor.
Definition post.h:211
Lik_MVN(double nugget)
Constructor given fiagonal nugget.
Definition post.h:209
Derived class for marginal likelihood.
Definition post.h:182
int nsam_
KDE sample size.
Definition post.h:196
double bdw_
KDE bandwidth.
Definition post.h:194
Lik_Marg(double bdw, int nsam)
Constructor given KDE bandwidth and sample size.
Definition post.h:185
~Lik_Marg()
Destructor.
Definition post.h:187
double evalLogLik(Array1D< double > &m)
Evaluate log-likelihood.
Definition post.cpp:497
multivariate RV parameterized by PC expansions
Definition mrv.h:48
posterior evaluation with various likelihood and prior options
Definition post.h:48
Array1D< double > yDatam_
ydata averaged per measurement
Definition post.h:100
Array2D< double > xData_
xdata
Definition post.h:96
Array1D< Array1D< double > > yData_
ydata
Definition post.h:98
Post()
Constructor.
Definition post.cpp:51
void * funcinfo_
Auxiliary information for function evaluation.
Definition post.h:121
Array1D< double > dataNoiseSig_
Data noise stdev.
Definition post.h:116
void setModel(Array1D< Array2D< double >(*)(Array2D< double > &, Array2D< double > &, Array2D< double > &, void *) > forwardFuncs, Array2D< double > &fixindnom, void *funcInfo)
Set a pointer to the forward model f(p,x)
Definition post.cpp:153
void inferLogDataNoise()
Indicate inference of log of data noise stdev.
Definition post.cpp:123
Array1D< double > upper_
Definition post.h:134
Array1D< double > dataSigma(double m_last)
Get data noise, whether inferred or fixed.
Definition post.cpp:133
bool dataNoiseLogFlag_
Flag to check if data noise logarithm is used.
Definition post.h:114
void setModelRVinput(int pdim, int order, Array1D< int > &rndInd, string pdfType, string pcType)
Set model input parameters' randomization scheme.
Definition post.cpp:163
Array1D< Array2D< double >(*)(Array2D< double > &, Array2D< double > &, Array2D< double > &, void *) > forwardFcns_
Pointer to the forward function f(p,x)
Definition post.h:119
double priora_
Prior parameter #1.
Definition post.h:142
Array1D< int > nEachs_
Number of samples at each input.
Definition post.h:104
void setDataNoise(Array1D< double > &sigma)
Set the magnitude of data noise.
Definition post.cpp:98
int nData_
Number of data points.
Definition post.h:102
int verbosity_
Verbosity level.
Definition post.h:149
Array1D< double > lower_
Lower and upper bounds on parameters.
Definition post.h:134
~Post()
Destructor.
Definition post.h:54
int pDim_
Dimensionality of parameter space (p-space)
Definition post.h:108
int chDim_
Dimensionality of posterior input.
Definition post.h:110
Array1D< int > rndInd_
Indices of randomized inputs.
Definition post.h:130
double evalLogPrior(Array1D< double > &m)
Evaluate log-prior.
Definition post.cpp:211
Array2D< double > samParam(Array1D< double > &m, int ns)
Sample model parameters given posterior input.
Definition post.cpp:338
Array2D< double > fixIndNom_
Indices and nominal values for fixed inputs.
Definition post.h:132
bool inferDataNoise_
Flag for data noise inference.
Definition post.h:112
int getChainDim()
Get the dimensionailty of the posterior function.
Definition post.cpp:195
void momParam(Array1D< double > &m, Array1D< double > &parMean, Array1D< double > &parVar, bool covFlag, Array2D< double > &parCov)
Get moments of parameters given posterior input.
Definition post.cpp:348
void setPrior(string priorType, double priora, double priorb)
Set the prior type and its parameters.
Definition post.cpp:201
int extraInferredParams_
Number of extra inferred parameters, such as data noise or Koh variance.
Definition post.h:123
void setData(Array2D< double > &xdata, Array2D< double > &ydata)
Set the x- and y-data.
Definition post.cpp:58
int xDim_
Dimensionality of x-space.
Definition post.h:106
Array2D< double > samForwardFcn(Array2D< double >(*forwardFunc)(Array2D< double > &, Array2D< double > &, Array2D< double > &, void *), Array1D< double > &m, Array2D< double > &xgrid, int ns)
Sample forward function at a given grid for given posterior input.
Definition post.cpp:360
double priorb_
Prior parameter #2.
Definition post.h:144
int ncat_
Number of categories.
Definition post.h:125
string priorType_
Prior type.
Definition post.h:140
Mrv * Mrv_
Pointer to a multivariate PC RV object.
Definition post.h:128
virtual double evalLogLik(Array1D< double > &m)
Dummy evaluation of log-likelihood.
Definition post.h:91
string pdfType_
Input parameter PDF type.
Definition post.h:136
void momForwardFcn(Array2D< double >(*forwardFunc)(Array2D< double > &, Array2D< double > &, Array2D< double > &, void *), Array1D< double > &m, Array2D< double > &xgrid, Array1D< double > &fcnMean, Array1D< double > &fcnVar, bool covflag, Array2D< double > &fcnCov)
Get moments of forward function at a given grid for given posterior input.
Definition post.cpp:372
string rvpcType_
PC type parameter for the r.v.
Definition post.h:138
Array2D< double > getParamPCcf(Array1D< double > &m)
Extract parameter PC coefficients from a posterior input.
Definition post.cpp:326
void inferDataNoise()
Indicate inference of data noise stdev.
Definition post.cpp:111
Header for multivariate random variable class.