@@ -316,7 +316,7 @@ struct HadronNucleiCorrelation {
316316 }
317317 }
318318
319- if (isMC) {
319+ if (isMC && doprocessMC ) {
320320 registry.add (" hPrimPrDCAxy" , " DCAxy p" , {HistType::kTH2D , {{600 , -3 .f , 3 .f , " DCA xy (cm)" }, {100 , 0 .f , 10 .f , " p_{T} GeV/c" }}});
321321 registry.add (" hPrimAntiPrDCAxy" , " DCAxy #bar{p}" , {HistType::kTH2D , {{600 , -3 .f , 3 .f , " DCA xy (cm)" }, {100 , 0 .f , 10 .f , " p_{T} GeV/c" }}});
322322 registry.add (" hPrimDeDCAxy" , " DCAxy d" , {HistType::kTH2D , {{600 , -3 .f , 3 .f , " DCA xy (cm)" }, {100 , 0 .f , 10 .f , " p_{T} GeV/c" }}});
@@ -409,17 +409,17 @@ struct HadronNucleiCorrelation {
409409 registry.add (" hGen_EtaPhiPt_Proton" , " Gen (anti)protons in gen collisions" , {HistType::kTH3F , {etaAxis, phiAxis, pTAxis_small}});
410410 registry.add (" hGen_EtaPhiPt_Deuteron" , " Gen (anti)deuteron in gen collisions" , {HistType::kTH3F , {etaAxis, phiAxis, pTAxis_small}});
411411
412- registry.add (" Generated/hQAProtons" , " hQAProtons" , {HistType::kTH1D , {{5 , 0 .f , 5 .f }}});
413- registry. get < TH1 >( HIST ( " Generated/hQAProtons " )) ->GetXaxis ()->SetBinLabel (1 , " All" );
414- registry. get < TH1 >( HIST ( " Generated/hQAProtons " )) ->GetXaxis ()->SetBinLabel (2 , " PhysicalPrimary" );
415- registry. get < TH1 >( HIST ( " Generated/hQAProtons " )) ->GetXaxis ()->SetBinLabel (3 , " |#eta|<0.8" );
416- registry. get < TH1 >( HIST ( " Generated/hQAProtons " )) ->GetXaxis ()->SetBinLabel (4 , " no daughters" );
417- registry. get < TH1 >( HIST ( " Generated/hQAProtons " )) ->GetXaxis ()->SetBinLabel (5 , " d daughter" );
418-
419- registry.add (" Generated/hQADeuterons" , " hQADeuterons" , {HistType::kTH1D , {{3 , 0 .f , 3 .f }}});
420- registry. get < TH1 >( HIST ( " Generated/hQADeuterons " )) ->GetXaxis ()->SetBinLabel (1 , " All" );
421- registry. get < TH1 >( HIST ( " Generated/hQADeuterons " )) ->GetXaxis ()->SetBinLabel (2 , " PhysicalPrimary" );
422- registry. get < TH1 >( HIST ( " Generated/hQADeuterons " )) ->GetXaxis ()->SetBinLabel (3 , " |#eta|<0.8" );
412+ auto hp = registry.add < TH1 > (" Generated/hQAProtons" , " hQAProtons" , {HistType::kTH1D , {{5 , 0 .f , 5 .f }}});
413+ hp ->GetXaxis ()->SetBinLabel (1 , " All" );
414+ hp ->GetXaxis ()->SetBinLabel (2 , " PhysicalPrimary" );
415+ hp ->GetXaxis ()->SetBinLabel (3 , " |#eta|<0.8" );
416+ hp ->GetXaxis ()->SetBinLabel (4 , " no daughters" );
417+ hp ->GetXaxis ()->SetBinLabel (5 , " d daughter" );
418+
419+ auto hd = registry.add < TH1 > (" Generated/hQADeuterons" , " hQADeuterons" , {HistType::kTH1D , {{3 , 0 .f , 3 .f }}});
420+ hd ->GetXaxis ()->SetBinLabel (1 , " All" );
421+ hd ->GetXaxis ()->SetBinLabel (2 , " PhysicalPrimary" );
422+ hd ->GetXaxis ()->SetBinLabel (3 , " |#eta|<0.8" );
423423
424424 registry.add (" Generated/hDeuteronsVsPt" , " hDeuteronsVsPt; p_{T} (GeV/c);" , {HistType::kTH1D , {{100 , 0 .f , 10 .f }}});
425425 registry.add (" Generated/hAntiDeuteronsVsPt" , " hAntiDeuteronsVsPt; p_{T} (GeV/c);" , {HistType::kTH1D , {{100 , 0 .f , 10 .f }}});
0 commit comments