show_sim.C

Vitaliy Schetinin, 09/19/2017 08:14 AM

Download (1.27 KB)

 
1
void show_sim()
2
{
3
        TFile *fr = new TFile("sim.root");
4
        TTree *tr = (TTree*)fr->Get("cbmsim");
5

    
6
        TCanvas *c1 = new TCanvas();
7
        tr->Draw("RTelescope1Si1Point.fELoss+RTelescope1Si2Point.fELoss", "RTelescope1Si1Point.fPID<3000 && RTelescope1Si2Point.fPID<3000");
8
        
9
        c1->Divide(3,2);
10

    
11
        c1->cd(1);
12
        tr->Draw("RTelescope1Si1Point.fY:RTelescope1Si1Point.fX", "", "box");
13
//        tr->Draw("RTelescope1Si1Point.fX", "", "box");
14

    
15
        c1->cd(3);
16
        tr->Draw("RTelescope1Si1Point.fELoss+RTelescope1Si2Point.fELoss+RTelescope1CsIPoint.fELoss",
17
                        "RTelescope1Si1Point.fPID<3000 && RTelescope1Si2Point.fPID<3000 && RTelescope1CsIPoint.fPID<3000");
18

    
19
        c1->cd(2);
20
        tr->Draw("RTelescope1Si1Point.fPID", "RTelescope1Si1Point.fPID>800000000");
21

    
22
        c1->cd(3);
23
        tr->Draw("RTelescope1Si1Point.fPID", "RTelescope1Si1Point.fPID<800000000");
24

    
25
        c1->cd(4);
26
        tr->Draw("Sum$(RTelescope1Si1Point.fELoss)+Sum$(RTelescope1Si2Point.fELoss)+Sum$(RTelescope1CsIPoint.fELoss)");
27
        
28
        c1->cd(5);
29
                tr->Draw("RTelescope1Si1Point.fELoss+RTelescope1Si2Point.fELoss",
30
                                "RTelescope1Si1Point.fPID<3000 && RTelescope1Si2Point.fPID<3000");
31

    
32
        c1->cd(6);
33
        tr->Draw("RTelescope1Si1Point.fELoss+RTelescope1Si2Point.fELoss+RTelescope1CsIPoint.fELoss",
34
                        "RTelescope1Si1Point.fPID>3000 && RTelescope1Si2Point.fPID>3000 && RTelescope1CsIPoint.fPID>3000");
35
        
36
}