25 #ifndef UQ_SEQUENCE_STATISTICAL_OPTIONS_H
26 #define UQ_SEQUENCE_STATISTICAL_OPTIONS_H
28 #include <queso/Defines.h>
30 #ifdef QUESO_USES_SEQUENCE_STATISTICAL_OPTIONS
32 #include <queso/Environment.h>
33 #include <queso/BoostInputOptionsParser.h>
35 #define UQ_SEQUENCE_INITIAL_DISCARDED_PORTIONS_ODV "0."
36 #ifdef QUESO_COMPUTES_EXTRA_POST_PROCESSING_STATISTICS
37 #define UQ_SEQUENCE_MEAN_MONITOR_PERIOD_ODV 0
38 #define UQ_SEQUENCE_BMM_RUN_ODV 0
39 #define UQ_SEQUENCE_BMM_LENGTHS_ODV "0"
40 #define UQ_SEQUENCE_BMM_DISPLAY_ODV 0
41 #define UQ_SEQUENCE_BMM_WRITE_ODV 0
42 #define UQ_SEQUENCE_FFT_COMPUTE_ODV 0
43 #define UQ_SEQUENCE_FFT_PARAM_ID_ODV 0
44 #define UQ_SEQUENCE_FFT_SIZE_ODV 2048
45 #define UQ_SEQUENCE_FFT_TEST_INVERSION_ODV 0
46 #define UQ_SEQUENCE_FFT_WRITE_ODV 0
47 #define UQ_SEQUENCE_PSD_COMPUTE_ODV 0
48 #define UQ_SEQUENCE_PSD_NUM_BLOCKS_ODV 8
49 #define UQ_SEQUENCE_PSD_HOP_SIZE_RATIO_ODV 0.
50 #define UQ_SEQUENCE_PSD_PARAM_ID_ODV 0
51 #define UQ_SEQUENCE_PSD_WRITE_ODV 0
52 #define UQ_SEQUENCE_PSD_AT_ZERO_COMPUTE_ODV 0
53 #define UQ_SEQUENCE_PSD_AT_ZERO_NUM_BLOCKS_ODV "8"
54 #define UQ_SEQUENCE_PSD_AT_ZERO_HOP_SIZE_RATIO_ODV .5
55 #define UQ_SEQUENCE_PSD_AT_ZERO_DISPLAY_ODV 0
56 #define UQ_SEQUENCE_PSD_AT_ZERO_WRITE_ODV 0
57 #define UQ_SEQUENCE_GEWEKE_COMPUTE_ODV 0
58 #define UQ_SEQUENCE_GEWEKE_NA_RATIO_ODV .1
59 #define UQ_SEQUENCE_GEWEKE_NB_RATIO_ODV .5
60 #define UQ_SEQUENCE_GEWEKE_DISPLAY_ODV 0
61 #define UQ_SEQUENCE_GEWEKE_WRITE_ODV 0
62 #define UQ_SEQUENCE_MEAN_STACC_COMPUTE_ODV 0
63 #define UQ_SEQUENCE_HIST_COMPUTE_ODV 0
64 #define UQ_SEQUENCE_HIST_NUM_INTERNAL_BINS_ODV 100
65 #define UQ_SEQUENCE_CDF_STACC_COMPUTE_ODV 0
66 #define UQ_SEQUENCE_CDF_STACC_NUM_EVAL_POSITIONS_ODV 50
68 #define UQ_SEQUENCE_AUTO_CORR_COMPUTE_VIA_DEF_ODV 0
69 #define UQ_SEQUENCE_AUTO_CORR_COMPUTE_VIA_FFT_ODV 0
70 #define UQ_SEQUENCE_AUTO_CORR_SECOND_LAG_ODV 0
71 #define UQ_SEQUENCE_AUTO_CORR_LAG_SPACING_ODV 0
72 #define UQ_SEQUENCE_AUTO_CORR_NUM_LAGS_ODV 0
73 #define UQ_SEQUENCE_AUTO_CORR_DISPLAY_ODV 0
74 #define UQ_SEQUENCE_AUTO_CORR_WRITE_ODV 0
75 #define UQ_SEQUENCE_KDE_COMPUTE_ODV 0
76 #define UQ_SEQUENCE_KDE_NUM_EVAL_POSITIONS_ODV 100
77 #define UQ_SEQUENCE_COV_MATRIX_COMPUTE_ODV 0
78 #define UQ_SEQUENCE_CORR_MATRIX_COMPUTE_ODV 0
81 namespace program_options {
82 class options_description;
162 #ifdef QUESO_COMPUTES_EXTRA_POST_PROCESSING_STATISTICS
222 #ifdef QUESO_COMPUTES_EXTRA_POST_PROCESSING_STATISTICS
278 const std::string& prefix);
284 const std::string& prefix,
332 void print(std::ostream& os)
const;
341 #ifdef QUESO_COMPUTES_EXTRA_POST_PROCESSING_STATISTICS
346 const std::vector<unsigned int>&
bmmLengths()
const;
385 void defineMyOptions (boost::program_options::options_description& optionsDesc)
const;
388 void getMyOptionValues(boost::program_options::options_description& optionsDesc);
409 #ifdef QUESO_COMPUTES_EXTRA_POST_PROCESSING_STATISTICS
446 #endif // ifdef QUESO_USES_SEQUENCE_STATISTICAL_OPTIONS
448 #endif // UQ_SEQUENCE_STATISTICAL_OPTIONS_H
std::string m_option_autoCorr_numLags
std::string m_option_hist_numInternalBins
BoostInputOptionsParser * m_parser
std::string m_option_psd_paramId
std::string m_option_autoCorr_computeViaFft
std::string m_option_kde_numEvalPositions
std::ostream & operator<<(std::ostream &os, const SequenceStatisticalOptions &obj)
std::string m_option_bmm_write
std::string m_option_autoCorr_lagSpacing
unsigned int autoCorrSecondLag() const
Returns the second lag of the autocorrelation. Access to private attribute m_autoCorrSecondLag.
std::string m_option_fft_testInversion
double m_psdAtZeroHopSizeRatio
std::string m_option_cdfStacc_numEvalPositions
unsigned int meanMonitorPeriod() const
std::string m_option_geweke_display
unsigned int autoCorrLagSpacing() const
Returns the spacing of the autocorrelation. Access to private attribute m_autoCorrLagSpacing.
unsigned int m_psdNumBlocks
std::string m_option_psd_hopSizeRatio
SsOptionsValues & operator=(const SsOptionsValues &rhs)
Assignment operator; it copies rhs to this.
std::string m_option_bmm_lengths
bool gewekeDisplay() const
std::string m_option_kde_compute
A templated class that stores statistical options (optionally read from an input file) ...
std::string m_option_initialDiscardedPortions
std::string m_option_psdAtZero_compute
const std::vector< double > & initialDiscardedPortions() const
Finds the initially discarded portion of the chain. Access to private attribute m_initialDiscardedPor...
std::string m_option_initialDiscardedPortions
unsigned int m_fftParamId
bool corrMatrixCompute() const
Finds the correlation matrix. Access to private attribute m_corrMatrixCompute.
std::string m_option_psd_hopSizeRatio
std::string m_option_autoCorr_write
bool covMatrixCompute() const
Finds the covariance matrix. Access to private attribute m_covMatrixCompute.
~SequenceStatisticalOptions()
Destructor.
std::string m_option_fft_paramId
std::string m_option_psdAtZero_compute
std::vector< unsigned int > m_bmmLengths
std::string m_option_meanStacc_compute
unsigned int m_meanMonitorPeriod
unsigned int histNumInternalBins() const
unsigned int kdeNumEvalPositions() const
Returns number of evaluation positions for KDE. Access to private attribute m_kdeNumEvalPositions.
double gewekeNbRatio() const
std::string m_option_autoCorr_numLags
std::string m_option_cdfStacc_compute
void print(std::ostream &os) const
Prints the initial discarded portion of the chain; and, optionally, other attributes of the chain...
std::string m_option_autoCorr_write
std::string m_option_psdAtZero_write
std::string m_option_psdAtZero_hopSizeRatio
void copy(const SsOptionsValues &src)
Copies the option values from src to this.
std::string m_option_bmm_lengths
std::string m_option_autoCorr_secondLag
unsigned int m_histNumInternalBins
const BaseEnvironment & m_env
std::string m_option_autoCorr_computeViaFft
std::string m_option_bmm_display
unsigned int m_cdfStaccNumEvalPositions
std::string m_option_geweke_naRatio
std::string m_option_psd_write
std::string m_option_geweke_compute
std::string m_option_psdAtZero_numBlocks
const std::vector< unsigned int > & bmmLengths() const
std::string m_option_geweke_nbRatio
std::string m_option_psd_compute
std::string m_option_autoCorr_display
unsigned int autoCorrNumLags() const
Returns the number of lags of the autocorrelation. Access to private attribute m_autoCorrNumLags.
bool m_corrMatrixCompute
Whether or not compute correlation matrix.
std::string m_option_psdAtZero_write
std::string m_option_covMatrix_compute
std::string m_option_fft_write
std::string m_option_kde_numEvalPositions
std::string m_option_hist_compute
std::vector< double > m_initialDiscardedPortions
Stores the initial discarded portion of the chain.
std::string m_option_hist_numInternalBins
std::string m_option_psdAtZero_display
bool cdfStaccCompute() const
virtual ~SsOptionsValues()
Destructor.
std::string m_option_psd_compute
const std::vector< unsigned int > & psdAtZeroNumBlocks() const
std::string m_option_fft_compute
std::string m_option_bmm_write
std::string m_option_cdfStacc_numEvalPositions
bool autoCorrComputeViaDef() const
Compute autocorrelation via definition. Access to private attribute m_autoCorrComputeViaDef.
std::string m_option_hist_compute
double psdHopSizeRatio() const
std::string m_option_mean_monitorPeriod
std::string m_option_help
std::string m_option_kde_compute
std::string m_option_psd_paramId
std::string m_option_cdfStacc_compute
std::vector< unsigned int > m_psdAtZeroNumBlocks
std::string m_option_autoCorr_computeViaDef
double gewekeNaRatio() const
unsigned int m_kdeNumEvalPositions
Number of positions to evaluate kde.
std::string m_option_fft_size
boost::program_options::options_description * m_optionsDesc
unsigned int m_autoCorrLagSpacing
Lag spacing of the autocorrelation.
std::string m_option_autoCorr_display
unsigned int cdfStaccNumEvalPositions() const
bool m_covMatrixCompute
Whether or not compute covariance matrix.
bool m_kdeCompute
Whether or not compute kernel density estimate (kde).
std::string m_option_geweke_nbRatio
std::string m_option_psdAtZero_numBlocks
bool m_autoCorrWrite
Whether or not write autocorrelation to file.
std::string m_option_psd_numBlocks
std::string m_option_psd_write
bool m_autoCorrDisplay
Whether or not display autocorrelation.
bool psdAtZeroWrite() const
std::string m_option_geweke_write
std::string m_option_psd_numBlocks
SequenceStatisticalOptions(const BaseEnvironment &env, const std::string &prefix)
Constructor: reads options from the input file.
std::string m_option_fft_compute
bool gewekeCompute() const
unsigned int m_autoCorrSecondLag
Second lag of the autocorrelation.
std::string m_option_fft_testInversion
unsigned int psdNumBlocks() const
std::string m_option_help
std::string m_option_psdAtZero_hopSizeRatio
std::string m_option_geweke_compute
std::string m_option_bmm_display
unsigned int psdParamId() const
std::string m_option_fft_paramId
unsigned int fftSize() const
std::string m_option_psdAtZero_display
void defineMyOptions(boost::program_options::options_description &optionsDesc) const
Defines the options for the chain.
std::string m_option_bmm_run
bool autoCorrDisplay() const
Displays autocorrelation. Access to private attribute m_autoCorrDisplay.
bool m_autoCorrComputeViaDef
Whether or not compute autocorrelation via definition.
bool psdAtZeroDisplay() const
double psdAtZeroHopSizeRatio() const
unsigned int m_psdParamId
std::string m_option_geweke_naRatio
std::string m_option_covMatrix_compute
std::string m_option_autoCorr_computeViaDef
unsigned int m_autoCorrNumLags
Number of lags of the autocorrelation.
bool meanStaccCompute() const
bool m_autoCorrComputeViaFft
Whether or not compute autocorrelation via FFT.
bool autoCorrComputeViaFft() const
Compute autocorrelation via FFT. Access to private attribute m_autoCorrComputeViaFft.
std::string m_option_corrMatrix_compute
std::string m_option_autoCorr_secondLag
std::string m_option_geweke_display
bool fftTestInversion() const
bool kdeCompute() const
Computes KDE. Access to private attribute m_kdeCompute.
std::string m_option_corrMatrix_compute
bool autoCorrWrite() const
Writes autocorrelation. Access to private attribute m_autoCorrWrite.
std::string m_option_fft_size
void getMyOptionValues(boost::program_options::options_description &optionsDesc)
Reads the chain options.
std::string m_option_geweke_write
std::string m_option_mean_monitorPeriod
std::string m_option_bmm_run
SsOptionsValues()
Default constructor.
std::string m_option_autoCorr_lagSpacing
std::string m_option_fft_write
bool psdAtZeroCompute() const
unsigned int fftParamId() const
std::string m_option_meanStacc_compute
A templated class that stores default statistical options for a sequence of vectors, e.g. a Markov chain, a Monte Carlo input sequence, or a Monte Carlo output sequence.