plotter.add_datasets(samples) plotter._overlayList.extend(['DATA_MUON']) #plotter._overlayList.extend(['FCNH']) #plotter.get_scale_factors(['FCNH']) plotter.get_scale_factors() ### VARIABLES ### ### First specify the directories in which your ### histograms are stored. If directories are ### not used enter '' as the only entry. Then ### list all of the variable names you wish to ### plot while giving a key value which is the ### directory that they are located in as a key. plotter._directoryList1D = ['Misc', 'Lepton', 'Dilepton', 'DileptonOS', 'MET', 'Jet', 'GEN'] plotter._directoryList2D = ['2D'] plotter._variableDict['Misc'] = ['PvMult', 'YieldByCut', 'EventWeight', 'TriggerStatus'] plotter._variableDict['Lepton'] = ['LeptonCharge', 'LeptonFlavor', 'Lepton1Pt', 'Lepton2Pt','Lepton3Pt', 'Lepton1Eta', 'Lepton2Eta', 'Lepton3Eta', 'Lepton1 dxy', 'Lepton1 dz', 'Lepton2 dxy', 'Lepton2 dz', 'Lepton3 dxy', 'Lepton3 dz', 'TrileptonMass', 'LeptonMult', '4lMass'] #'Lepton1Phi', 'Lepton2Phi', 'Lepton3Phi'] plotter._variableDict['Dilepton'] = ['DileptonMass21', 'DileptonTransMass21', 'DileptonQt21', 'DileptonDeltaPhi21', 'DileptonDeltaEta21', 'DileptonDeltaR21', 'DileptonDeltaPt21',
r.gROOT.SetBatch() ### Initialize plot producer ### plotter = PlotProducer(inputFile = 'fakeEstimator/histos/{0}.root'.format(batch), savePath = '', scale = LUMIDATA, isAFS = False) plotter.set_period(period) plotter.set_output_type(plotType) plotter.set_save_path('plots/{0}/{1}_{2}_{3}/log'.format(currentDate, selection, batch, suffix)) ### DATASETS ### plotter.add_datasets(samples['inclusive']) plotter._overlayList.extend(['DATA']) plotter.get_scale_factors(corrected = False) plotter._directoryList1D = ['Muon', 'Electron'] plotter._variableDict['Muon'] = ['MuPassLepPt', 'MuPassLepEta', 'MuPassTransverseMass', 'MuProbeLepPt', 'MuProbeLepEta', 'MuProbeTransverseMass', 'MuNumerPt', 'MuNumerEta', 'MuNumerMet', 'MuNumerIsoRel', 'MuDenomPt', 'MuDenomEta', 'MuDenomMet', 'MuDenomIsoRel', 'MuNumerPtLowJet', 'MuNumerPtHighJet', 'MuDenomPtLowJet', 'MuDenomPtHighJet', 'MuDenomIsoRelBin1', 'MuDenomIsoRelBin2', 'MuFailLepPt', 'MuFailLepEta', 'MuFailTransverseMass', 'MuTagLepPt', 'MuTagLepEta', 'MuTagIsoRel', 'MuTagDz', 'MuTagDxy', 'TagMuPassMass', 'TagMuPassDeltaR', 'TagMuProbeMass', 'TagMuProbeDeltaR', 'TagMuProbeDeltaPhi', 'TagMuProbePtBalance', 'TagMuFailMass', 'TagMuFailDeltaR', 'MuJetMult_tight', 'MuJetMult_inclusive', 'MuJetMult_fail']
plotter._overlayList.extend(['DATA']) plotter._overlayList.extend(['FCNH', 'FCNHUp']) #plotter.get_scale_factors() plotter.get_scale_factors(['FCNH', 'FCNHUp']) ### VARIABLES ### ### First specify the directories in which your ### histograms are stored. If directories are ### not used enter '' as the only entry. Then ### list all of the variable names you wish to ### plot while giving a key value which is the ### directory that they are located in as a key. #plotter._directoryList1D = ['Electron'] plotter._directoryList1D = ['Misc', 'Electron', 'Lepton', 'Lep+Jet', 'Dilepton', 'DileptonOS', 'Trilepton', 'MET', 'Jet', 'GEN', '4l'] #plotter._directoryList1D = ['Lepton', 'Lep+Jet', 'Dilepton', 'DileptonOS', 'Trilepton', 'MET', 'Jet', 'GEN', '4l'] plotter._directoryList2D = ['2D'] plotter._variableDict['Misc'] = ['PvMult', 'YieldByCut', 'YieldByCutRaw', 'EventWeight', 'TriggerStatus', 'BDT'] plotter._variableDict['Electron'] = [ 'ElectronPt', 'ElectronEta', 'LeadElectronEta', 'TrailingElectronEta', 'ElectronDxy', 'ElectronDz', 'ElectronIsoRel', 'ElectronIso', 'LeadElectronPtBB', 'LeadElectronPtBE', 'LeadElectronPtBT', 'LeadElectronPtTB', 'LeadElectronPtTE', 'LeadElectronPtTT', 'LeadElectronPtEB', 'LeadElectronPtEE', 'LeadElectronPtET', 'TrailingElectronPtBB', 'TrailingElectronPtBE', 'TrailingElectronPtBT', 'TrailingElectronPtTB', 'TrailingElectronPtTE', 'TrailingElectronPtTT',
### DATASETS ### ### Specify the datasets you wish to stack ### and overlay accordingly. plotter.add_datasets(samples['all']) plotter.get_scale_factors() ### VARIABLES ### ### First specify the directories in which your ### histograms are stored. If directories are ### not used enter '' as the only entry. Then ### list all of the variable names you wish to ### plot while giving a key value which is the ### directory that they are located in as a key. plotter._directoryList1D = ['Misc', 'Lepton', 'Lep+Jet', 'Dilepton', 'DileptonOS', 'Trilepton', 'MET', 'Jet', 'Fakes'] plotter._variableDict['Misc'] = ['PvMult', 'YieldByCut', 'YieldByCutRaw', 'EventWeight', 'TriggerStatus', 'FakeWeightUncertainty', 'BDT', 'FakeCategory'] plotter._variableDict['Lepton'] = ['LeptonCharge', 'LeptonFlavor', 'Lepton1Pt', 'Lepton2Pt','Lepton3Pt', 'Lepton1Eta', 'Lepton2Eta', 'Lepton3Eta', 'ElectronPt', 'ElectronEta', 'MuonPt', 'MuonEta', 'Lepton1dxy', 'Lepton1dz', 'Lepton2dxy', 'Lepton2dz', 'Lepton3dxy', 'Lepton3dz', 'LeptonMult', 'fakeableOverlapMult' 'OverlapEleMu', 'MuEleDeltaR'] #'Lepton1Phi', 'Lepton2Phi', 'Lepton3Phi']
### and overlay accordingly. plotter.add_datasets(samples) plotter._overlayList.extend(['DATA_MUON']) plotter.get_scale_factors() ### VARIABLES ### ### First specify the directories in which your ### histograms are stored. If directories are ### not used enter '' as the only entry. Then ### list all of the variable names you wish to ### plot while giving a key value which is the ### directory that they are located in as a key. plotter._directoryList1D = ['fakes'] #plotter._directoryList2D = ['2D_Dilepton'] #plotter._variableDict['fakes'] = ['leptonMult', 'jetMult', 'bJetMult'] plotter._variableDict['fakes'] = ['DileptonMass'] ################### ### MAKE PLOTS! ### ################### r.gROOT.SetStyle('Plain') r.gStyle.SetOptStat(0) plotter.set_input_file('histos/fakeHistograms.root') plotter.set_save_path('../plots/fakes/' + currentDate)