void showHistOutput() { TFile *fr = new TFile("histOutput.root"); TH1D *hch[64]; TString histName; for (Int_t i = 0; i<64; i++) { histName.Form("ch%d", i); hch[i] = (TH1D*)fr->Get(histName.Data()); } //canvases to show 1D histograms TString cName; TString cTitle; const Int_t pads = 9; const Int_t noCanvas = 64/pads+1; const Double_t xmin = 100; const Double_t xmax = 2000.; TCanvas *cWork[noCanvas]; for (Int_t i = 0; i < noCanvas; i++) { cName.Form("can%d", i); cTitle.Form("canvas %d", i); cWork[i] = new TCanvas(cName.Data(), cTitle.Data(), 0, 0, 960, 700); // cWork[i]->SetName(cName.Data()); // cWork[i]->SetTitle(cTitle.Data()); if (pads == 6) cWork[i]->Divide(2, 3); if (pads == 9) cWork[i]->Divide(3, 3); cWork[i]->cd(1); } for (Int_t i = 0; i < 64; i++) { histName.Form("ch%d", i); // hTitle.Form("channel %d", i); // hTemp = h2->ProjectionY(hName.Data(), i+1, i+1); // hTemp->SetTitle(hTitle.Data()); // hTemp->GetXaxis()->SetRangeUser(0, 2000); Int_t cNumber = i/pads; cWork[cNumber]->cd(i-pads*cNumber+1); hch[i]->Draw(); hch[i]->GetXaxis()->SetRangeUser(xmin, xmax); } }