showBeamDetElossSim.C

восстановление картин - Vratislav Chudoba, 03/05/2018 07:13 PM

Download (914 Bytes)

 
1
void showBeamDetElossSim()
2
{
3

    
4
        TFile *fr = new TFile("sim.root", "READ");
5
        TTree *tr = (TTree*)fr->Get("er");
6

    
7
        TFile *freco = new TFile("reco.root", "READ");
8
        TTree *treco = (TTree*)freco->Get("er");
9

    
10
        TCanvas *c1 = new TCanvas("c1", "MWPC profiles", 1200, 800);
11
        c1->Divide(3,2);
12

    
13
        c1->cd(1);
14
//        tr->Draw("MCTrack.fMass*1000", "MCTrack.fPdgCode == 1000020060");
15
        treco->Draw("BeamDetParticle.fTofState.fE*1000 - 5606.556", "");
16

    
17

    
18
        c1->cd(2);
19

    
20
        treco->Draw("BeamDetParticle.fTargetState.fE*1000 - 5606.556", "");
21

    
22
        c1->cd(3);
23
        treco->Draw("BeamDetParticle.fTargetState.fE*1000 - 5606.556", "BeamDetTrack.fXt && BeamDetTrack.fYt");
24

    
25

    
26
        c1->cd(4);
27
        treco->Draw("BeamDetParticle.fTofState.fE*1000 - 5606.556", "BeamDetParticle.fPID == 1000020060");
28

    
29
        c1->cd(5);
30
        treco->Draw("BeamDetParticle.fTargetState.fE*1000 - 5606.556", "TMath::Abs(BeamDetTrack.fXt)<0.1 && TMath::Abs(BeamDetTrack.fYt)<0.1");
31

    
32

    
33
        c1->cd(6);
34

    
35

    
36
}