![]() |
MaCh3
2.4.2
Reference Guide
|
KS: This script is used to analyse output form DiagMCMC. More...
#include "Fitters/MCMCProcessor.h"#include "Samples/HistogramUtils.h"#include "THStack.h"#include "TGraphAsymmErrors.h"#include "TLegend.h"#include <TSystem.h>Go to the source code of this file.
Functions | |
| double | GetMinimumInRange (TH1D *hist, const double minRange, const double maxRange) |
| KS: function which looks for minimum in given range. More... | |
| bool | IsHistogramAllOnes (TH1D *hist, double tolerance=0.001, int max_failures=100) |
| HW: Check if histogram is flat within a given tolerance. More... | |
| void | MakeDiagPlot (std::vector< TString > input_files, std::vector< TString > hist_labels) |
| function which loops over Diag MCMC output and prints everything to PDF More... | |
| void | PlotAutoCorr (const std::vector< TString > &fname) |
| Plot autocorrelation for all params into single plot with color codding helping whether on average it is ok or not. More... | |
| std::pair< std::unique_ptr< TGraph >, std::unique_ptr< TGraph > > | CreateMinMaxBand (TH1D *hist, Color_t color) |
| HW: Create a band of minimum and maximum values from a histogram. More... | |
| std::unique_ptr< TGraphAsymmErrors > | CalculateMinMaxBand (const std::vector< std::unique_ptr< TH1D >> &histograms, Color_t color) |
| void | ProcessAutoCorrelationDirectory (TDirectoryFile *autocor_dir, std::unique_ptr< TH1D > &average_hist, int ¶meter_count, std::vector< std::unique_ptr< TH1D >> &histograms) |
| Loop over directory get histograms into vector and add to averaged hist. More... | |
| void | ProcessDiagnosticFile (const TString &file_path, std::unique_ptr< TH1D > &average_hist, int ¶meter_count, std::vector< std::unique_ptr< TH1D >> &histograms) |
| std::unique_ptr< TH1D > | AutocorrProcessInputs (const TString &input_file, std::vector< std::unique_ptr< TH1D >> &histograms) |
| void | CompareAverageAC (const std::vector< std::vector< std::unique_ptr< TH1D >>> &histograms, const std::vector< std::unique_ptr< TH1D >> &averages, const std::vector< TString > &hist_labels, const TString &output_name, bool draw_min_max=true, bool draw_all=false, bool draw_errors=true) |
| void | PlotAverageACMult (std::vector< TString > input_files, std::vector< TString > hist_labels, const TString &output_name, bool draw_min_max=true, bool draw_all=false, bool draw_errors=true) |
| Calculate mean AC based on all parameters with error band. Great for comparing AC between different chains. More... | |
| int | main (int argc, char *argv[]) |
KS: This script is used to analyse output form DiagMCMC.
Definition in file PlotMCMCDiag.cpp.
| std::unique_ptr<TH1D> AutocorrProcessInputs | ( | const TString & | input_file, |
| std::vector< std::unique_ptr< TH1D >> & | histograms | ||
| ) |
Definition at line 356 of file PlotMCMCDiag.cpp.
| std::unique_ptr<TGraphAsymmErrors> CalculateMinMaxBand | ( | const std::vector< std::unique_ptr< TH1D >> & | histograms, |
| Color_t | color | ||
| ) |
Definition at line 267 of file PlotMCMCDiag.cpp.
| void CompareAverageAC | ( | const std::vector< std::vector< std::unique_ptr< TH1D >>> & | histograms, |
| const std::vector< std::unique_ptr< TH1D >> & | averages, | ||
| const std::vector< TString > & | hist_labels, | ||
| const TString & | output_name, | ||
| bool | draw_min_max = true, |
||
| bool | draw_all = false, |
||
| bool | draw_errors = true |
||
| ) |
Definition at line 376 of file PlotMCMCDiag.cpp.
| std::pair<std::unique_ptr<TGraph>, std::unique_ptr<TGraph> > CreateMinMaxBand | ( | TH1D * | hist, |
| Color_t | color | ||
| ) |
HW: Create a band of minimum and maximum values from a histogram.
Definition at line 244 of file PlotMCMCDiag.cpp.
| double GetMinimumInRange | ( | TH1D * | hist, |
| const double | minRange, | ||
| const double | maxRange | ||
| ) |
KS: function which looks for minimum in given range.
Definition at line 20 of file PlotMCMCDiag.cpp.
| bool IsHistogramAllOnes | ( | TH1D * | hist, |
| double | tolerance = 0.001, |
||
| int | max_failures = 100 |
||
| ) |
HW: Check if histogram is flat within a given tolerance.
Definition at line 36 of file PlotMCMCDiag.cpp.
| int main | ( | int | argc, |
| char * | argv[] | ||
| ) |
Definition at line 488 of file PlotMCMCDiag.cpp.
| void MakeDiagPlot | ( | std::vector< TString > | input_files, |
| std::vector< TString > | hist_labels | ||
| ) |
function which loops over Diag MCMC output and prints everything to PDF
Definition at line 54 of file PlotMCMCDiag.cpp.
| void PlotAutoCorr | ( | const std::vector< TString > & | fname | ) |
Plot autocorrelation for all params into single plot with color codding helping whether on average it is ok or not.
Definition at line 155 of file PlotMCMCDiag.cpp.
| void PlotAverageACMult | ( | std::vector< TString > | input_files, |
| std::vector< TString > | hist_labels, | ||
| const TString & | output_name, | ||
| bool | draw_min_max = true, |
||
| bool | draw_all = false, |
||
| bool | draw_errors = true |
||
| ) |
Calculate mean AC based on all parameters with error band. Great for comparing AC between different chains.
Definition at line 458 of file PlotMCMCDiag.cpp.
| void ProcessAutoCorrelationDirectory | ( | TDirectoryFile * | autocor_dir, |
| std::unique_ptr< TH1D > & | average_hist, | ||
| int & | parameter_count, | ||
| std::vector< std::unique_ptr< TH1D >> & | histograms | ||
| ) |
Loop over directory get histograms into vector and add to averaged hist.
Definition at line 303 of file PlotMCMCDiag.cpp.
| void ProcessDiagnosticFile | ( | const TString & | file_path, |
| std::unique_ptr< TH1D > & | average_hist, | ||
| int & | parameter_count, | ||
| std::vector< std::unique_ptr< TH1D >> & | histograms | ||
| ) |
Definition at line 333 of file PlotMCMCDiag.cpp.