Changeset 4367 for trunk/MagicSoft
- Timestamp:
- 06/30/04 15:42:27 (20 years ago)
- Location:
- trunk/MagicSoft/Mars/mtemp/mifae
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/MagicSoft/Mars/mtemp/mifae/Changelog
r4356 r4367 18 18 19 19 -*-*- END OF LINE -*-*- 20 21 2004/06/30: Javier Rico 22 23 * mifae/library/MDisp.cc 24 - Remove include of deprecated library 25 - Define namespace 26 27 * mifae/library/MControlPlots.cc 28 - Define style 29 - Add projection 30 - Plot 3rd plot correctly 31 - Search for "MIsland" instead of "MIsland1" container 20 32 21 33 2004/06/26: Eva Domingo - Pepe Flix -
trunk/MagicSoft/Mars/mtemp/mifae/library/MControlPlots.cc
r4364 r4367 31 31 #include <fstream> 32 32 33 #include "TStyle.h" 34 33 35 #include "MParList.h" 34 36 #include "MControlPlots.h" … … 86 88 87 89 // look for MIslands object 88 fIslands = (MIslands*)pList->FindObject("MIslands 1");90 fIslands = (MIslands*)pList->FindObject("MIslands"); 89 91 if (!fIslands) 90 92 *fLog << warn << AddSerialNumber("MIslands") << " [MIslands] not found... Some control plots will not be produced" << endl; … … 129 131 } 130 132 133 // Canvas style 134 gStyle->SetCanvasColor(0); 135 gStyle->SetCanvasBorderMode(0); 136 gStyle->SetPadBorderMode(0); 137 gStyle->SetFrameBorderMode(0); 138 gStyle->SetStatColor(0); 139 gStyle->SetTitleFillColor(0); 140 131 141 TCanvas* c = new TCanvas("survivals","Pixels surviving Image Cleaning",800,800); 142 MHCamera* diff=NULL; 132 143 133 144 // in case both on and off histos are present, print both and the difference between them 134 145 if(fCameraHisto[kOn] && fCameraHisto[kOff]) 135 146 { 136 MHCamera diff(*fGeomCam,"Diff","Pixels surviving Image Cleaning");147 diff = new MHCamera(*fGeomCam,"Diff","Pixels surviving Image Cleaning"); 137 148 138 for(Int_t i=1;i< =diff.GetSize()-2;i++)149 for(Int_t i=1;i<diff->GetSize()-2;i++) 139 150 { 140 diff .SetBinContent(i,(Double_t)fCameraHisto[kOn]->GetBinContent(i)-fCameraHisto[kOff]->GetBinContent(i));141 diff .SetUsed(i);151 diff->SetBinContent(i,(Double_t)fCameraHisto[kOn]->GetBinContent(i)-fCameraHisto[kOff]->GetBinContent(i)); 152 diff->SetUsed(i); 142 153 } 143 154 fCameraHisto[kOn]->SetPrettyPalette(); 144 155 fCameraHisto[kOff]->SetPrettyPalette(); 145 diff .SetPrettyPalette();156 diff->SetPrettyPalette(); 146 157 147 158 c->Divide(2,2); 148 159 160 Float_t max = TMath::Max(fCameraHisto[kOn]->GetMaximum(),fCameraHisto[kOff]->GetMaximum()); 161 Float_t min = TMath::Min(fCameraHisto[kOn]->GetMinimum(),fCameraHisto[kOff]->GetMinimum()); 162 fCameraHisto[kOn]->SetMaximum(max); 163 fCameraHisto[kOn]->SetMinimum(min); 164 fCameraHisto[kOff]->SetMaximum(max); 165 fCameraHisto[kOff]->SetMinimum(min); 166 149 167 c->cd(1); 150 168 fCameraHisto[kOn]->Draw(); … … 158 176 159 177 c->cd(3); 160 diff .Draw();178 diff->Draw(); 161 179 gPad->Modified(); 162 180 gPad->Update(); 181 182 c->cd(4); 183 diff->DrawProjection(); 184 gPad->Modified(); 185 gPad->Update(); 163 186 } 164 187 // plot the existing histo … … 173 196 c->SaveAs(fFileName); 174 197 delete c; 198 if(diff) 199 delete diff; 175 200 return kTRUE; 176 201 } -
trunk/MagicSoft/Mars/mtemp/mifae/library/MDisp.cc
r4316 r4367 44 44 #include "MDisp.h" 45 45 46 #include <iostream .h>46 #include <iostream> 47 47 //#include <TArrayF.h> 48 48 … … 50 50 #include "MLogManip.h" 51 51 52 using namespace std; 52 53 ClassImp(MDisp); 53 54
Note:
See TracChangeset
for help on using the changeset viewer.