ExportHistograms

Export histograms from a workspace.

Usage:

+ExportHistograms{
  +HWWRun2GGF {
    # export a set of postfit histograms
    +postfit {
      <snapshot="SnSh_NuisPOI_Unconditional_observed_muhat">
      <outputFile="workspaces/run2-ggf-$(fitLabel)/histograms-postFit.root">
      <dataName="obsData">
      <fitResult="HWWRun2GGF/Significance/observed/FitResults/observed_muhat">
    }
    # also export a set of prefit histograms
    +prefit {
      <snapshot="SnSh_AllVars_Nominal">
      <outputFile="workspaces/run2-ggf-$(fitLabel)/histograms-preFit.root">
      <dataName="obsData">
      <constPars={"*_norm_*","muGGF"}>
    }

    @?{
      <singleRegions=false>
      +CombinedSamples{
        +top {
          <Components={"ttbar*","wt*"}>
        }
        +higgs {
          <Components={"sig*","otherH*"}>
        }
        +VV {
          <Components={"Vgamma*","*NonWW*"}>
        }
        +WW {
          <Components={"ggWW*","*qqWW*"}>
        }
      }
      +CombinedRegions{
        +SR_0j_DF_all {
          <Components="SR_*0j*">
        }
        +SR_1j_DF_all {
          <Components="SR_*1j*">
        }
        +SR_DF_all {
          <Components="SR_*">
        }
        +all {
          <Components="*">
        }                
      }
    }
#    <normPattern="ATLAS_HWWlvlvGGF_sampleNorm_$(SAMPLENAME)">
     <cloneStyle="HWWRun2GGF/.Histograms/Nominal"> @?;

#    <export.decorrelate={"theo_*"}> @?;
#    <export.correlate={"*"}> @?;      
  }
}

Subfolders can be provided to the action to write more than one set of histograms. Each of these sets can be configured separately. The following configuration options are supported:

Normalization Pattern vs. selectComponents

This action can use one of two strategies to extract histograms from a workspace, either of which has its own limitations. In order to extract histograms, some components of the pdf need to be activated/deactivated selectively, such that the different contributions (samples) can be isolated. For this, two mechanisms exist.