Page MenuHomeHEPForge

bmix.script
No OneTemporary

Size
1 KB
Referenced Files
None
Subscribers
None

bmix.script

/***********************************************************************
* Copyright 1998-2020 CERN for the benefit of the EvtGen authors *
* *
* This file is part of EvtGen. *
* *
* EvtGen is free software: you can redistribute it and/or modify *
* it under the terms of the GNU General Public License as published by *
* the Free Software Foundation, either version 3 of the License, or *
* (at your option) any later version. *
* *
* EvtGen is distributed in the hope that it will be useful, *
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
* GNU General Public License for more details. *
* *
* You should have received a copy of the GNU General Public License *
* along with EvtGen. If not, see <https://www.gnu.org/licenses/>. *
***********************************************************************/
{
TFile *myFile = new TFile("bmix.root","READ");
myFile->ls();
TCanvas *myCanvas = new TCanvas("c","bmix",0,0,600,400);
myCanvas->Divide(2,3);
TH1F *th1=h1;
TH1F *th2=h2;
TH1F *th3=h3;
TH1F *th4=h3;
TH1F* diff=new TH1F(*h1+*h2-(*h3+*h4));
TH1F* sum=new TH1F(*h1+*h2+(*h3+*h4));
TH1F* ratio=new TH1F((*diff)/(*sum));
myCanvas->cd(1);
th1->Draw();
myCanvas.Update();
myCanvas->cd(2);
th2->Draw();
myCanvas.Update();
myCanvas->cd(3);
th3->Draw();
myCanvas.Update();
myCanvas->cd(4);
th4->Draw();
myCanvas.Update();
myCanvas->cd(5);
ratio->Draw();
myCanvas.Update();
myCanvas->Print("bmix.eps");
}

File Metadata

Mime Type
text/plain
Expires
Tue, Sep 30, 4:44 AM (1 d, 8 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
6547550
Default Alt Text
bmix.script (1 KB)

Event Timeline