Geant4 Cross Reference |
1 // 1 // 2 // ******************************************* 2 // ******************************************************************** 3 // * License and Disclaimer 3 // * License and Disclaimer * 4 // * 4 // * * 5 // * The Geant4 software is copyright of th 5 // * The Geant4 software is copyright of the Copyright Holders of * 6 // * the Geant4 Collaboration. It is provided 6 // * the Geant4 Collaboration. It is provided under the terms and * 7 // * conditions of the Geant4 Software License 7 // * conditions of the Geant4 Software License, included in the file * 8 // * LICENSE and available at http://cern.ch/ 8 // * LICENSE and available at http://cern.ch/geant4/license . These * 9 // * include a list of copyright holders. 9 // * include a list of copyright holders. * 10 // * 10 // * * 11 // * Neither the authors of this software syst 11 // * Neither the authors of this software system, nor their employing * 12 // * institutes,nor the agencies providing fin 12 // * institutes,nor the agencies providing financial support for this * 13 // * work make any representation or warran 13 // * work make any representation or warranty, express or implied, * 14 // * regarding this software system or assum 14 // * regarding this software system or assume any liability for its * 15 // * use. Please see the license in the file 15 // * use. Please see the license in the file LICENSE and URL above * 16 // * for the full disclaimer and the limitatio 16 // * for the full disclaimer and the limitation of liability. * 17 // * 17 // * * 18 // * This code implementation is the result 18 // * This code implementation is the result of the scientific and * 19 // * technical work of the GEANT4 collaboratio 19 // * technical work of the GEANT4 collaboration. * 20 // * By using, copying, modifying or distri 20 // * By using, copying, modifying or distributing the software (or * 21 // * any work based on the software) you ag 21 // * any work based on the software) you agree to acknowledge its * 22 // * use in resulting scientific publicati 22 // * use in resulting scientific publications, and indicate your * 23 // * acceptance of all terms of the Geant4 Sof 23 // * acceptance of all terms of the Geant4 Software license. * 24 // ******************************************* 24 // ******************************************************************** 25 // 25 // 26 /// \file electromagnetic/TestEm9/src/Histo.cc 26 /// \file electromagnetic/TestEm9/src/Histo.cc 27 /// \brief Implementation of the Histo class 27 /// \brief Implementation of the Histo class 28 // 28 // 29 // 29 // 30 //-------------------------------------------- 30 //--------------------------------------------------------------------------- 31 // 31 // 32 // ClassName: Histo - Generic histogram/ntup 32 // ClassName: Histo - Generic histogram/ntuple manager class 33 // 33 // 34 // 34 // 35 // Author: V.Ivanchenko 30.10.03 35 // Author: V.Ivanchenko 30.10.03 36 // 36 // 37 //-------------------------------------------- 37 //---------------------------------------------------------------------------- 38 // 38 // 39 39 40 //....oooOO0OOooo........oooOO0OOooo........oo 40 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 41 //....oooOO0OOooo........oooOO0OOooo........oo 41 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 42 42 43 #include "Histo.hh" 43 #include "Histo.hh" 44 << 45 #include "HistoMessenger.hh" 44 #include "HistoMessenger.hh" 46 << 47 #include "G4RootAnalysisManager.hh" 45 #include "G4RootAnalysisManager.hh" 48 46 49 //....oooOO0OOooo........oooOO0OOooo........oo 47 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 50 //....oooOO0OOooo........oooOO0OOooo........oo 48 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 51 49 52 Histo::Histo() : fManager(0), fMessenger(0) << 50 Histo::Histo() >> 51 : fManager(0), >> 52 fMessenger(0) 53 { 53 { 54 fMessenger = new HistoMessenger(this); 54 fMessenger = new HistoMessenger(this); 55 << 55 56 fHistName = "test"; << 56 fHistName = "test"; 57 fHistType = "root"; << 57 fHistType = "root"; 58 fTupleName = "tuple"; << 58 fTupleName = "tuple"; 59 fTupleTitle = "test"; 59 fTupleTitle = "test"; 60 fNHisto = 0; << 60 fNHisto = 0; 61 fVerbose = 0; << 61 fVerbose = 0; 62 fDefaultAct = true; 62 fDefaultAct = true; 63 fHistoActive = false; << 63 fHistoActive= false; 64 fNtupleActive = false; << 64 fNtupleActive= false; 65 } 65 } 66 66 67 //....oooOO0OOooo........oooOO0OOooo........oo 67 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 68 68 69 Histo::~Histo() 69 Histo::~Histo() 70 { 70 { 71 delete fMessenger; 71 delete fMessenger; 72 } 72 } 73 73 74 //....oooOO0OOooo........oooOO0OOooo........oo 74 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 75 75 76 void Histo::Book() 76 void Histo::Book() 77 { 77 { 78 if (!(fHistoActive || fNtupleActive)) { << 78 if(!(fHistoActive || fNtupleActive)) { return; } 79 return; << 80 } << 81 79 82 // Always creating analysis manager 80 // Always creating analysis manager 83 fManager = G4RootAnalysisManager::Instance() << 81 fManager = G4RootAnalysisManager::Instance(); 84 82 85 // Creating a tree mapped to a new hbook fil 83 // Creating a tree mapped to a new hbook file. 86 G4String nam = fHistName + "." + fHistType; 84 G4String nam = fHistName + "." + fHistType; 87 85 88 // Open file histogram file 86 // Open file histogram file 89 if (!fManager->OpenFile(nam)) { << 87 if(!fManager->OpenFile(nam)) { 90 G4cout << "Histo::Book: ERROR open file <" 88 G4cout << "Histo::Book: ERROR open file <" << nam << ">" << G4endl; 91 fHistoActive = false; 89 fHistoActive = false; 92 fNtupleActive = false; 90 fNtupleActive = false; 93 return; << 91 return; 94 } 92 } 95 G4cout << "### Histo::Save: Opended file <" << 93 G4cout << "### Histo::Save: Opended file <" << nam << "> for " 96 << G4endl; << 94 << fNHisto << " histograms " << G4endl; 97 95 98 // Creating an 1-dimensional histograms in t 96 // Creating an 1-dimensional histograms in the root directory of the tree 99 for (G4int i = 0; i < fNHisto; ++i) { << 97 for(G4int i=0; i<fNHisto; ++i) { 100 if (fActive[i]) { << 98 if(fActive[i]) { 101 G4String ss = "h" + fIds[i]; 99 G4String ss = "h" + fIds[i]; 102 fHisto[i] = fManager->CreateH1(ss, fTitl << 100 fHisto[i] = 103 if (fVerbose > 0) { << 101 fManager->CreateH1(ss, fTitles[i], fBins[i], fXmin[i], fXmax[i]); 104 G4cout << "Created histogram #" << i < << 102 if(fVerbose > 0) { 105 << fTitles[i] << G4endl; << 103 G4cout << "Created histogram #" << i << " id= " << fHisto[i] >> 104 << " " << ss << " " << fTitles[i] << G4endl; 106 } 105 } 107 } 106 } 108 } 107 } 109 // Creating a tuple factory, whose tuples wi 108 // Creating a tuple factory, whose tuples will be handled by the tree 110 if (fNtupleActive) { << 109 if(fNtupleActive) { 111 fManager->CreateNtuple(fTupleName, fTupleT << 110 fManager->CreateNtuple(fTupleName,fTupleTitle); 112 G4int i; 111 G4int i; 113 G4int n = fNtupleI.size(); 112 G4int n = fNtupleI.size(); 114 for (i = 0; i < n; ++i) { << 113 for(i=0; i<n; ++i) { 115 if (fTupleI[i] == -1) { << 114 if(fTupleI[i] == -1) { 116 fTupleI[i] = fManager->CreateNtupleICo << 115 fTupleI[i] = fManager->CreateNtupleIColumn(fNtupleI[i]); 117 } 116 } 118 } 117 } 119 n = fNtupleF.size(); 118 n = fNtupleF.size(); 120 for (i = 0; i < n; ++i) { << 119 for(i=0; i<n; ++i) { 121 if (fTupleF[i] == -1) { << 120 if(fTupleF[i] == -1) { 122 fTupleF[i] = fManager->CreateNtupleFCo << 121 fTupleF[i] = fManager->CreateNtupleFColumn(fNtupleF[i]); 123 } 122 } 124 } 123 } 125 n = fNtupleD.size(); 124 n = fNtupleD.size(); 126 for (i = 0; i < n; ++i) { << 125 for(i=0; i<n; ++i) { 127 if (fTupleD[i] == -1) { << 126 if(fTupleD[i] == -1) { 128 fTupleD[i] = fManager->CreateNtupleDCo << 127 fTupleD[i] = fManager->CreateNtupleDColumn(fNtupleD[i]); 129 } 128 } 130 } 129 } 131 } 130 } 132 } << 131 } 133 132 134 //....oooOO0OOooo........oooOO0OOooo........oo 133 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 135 134 136 void Histo::Save() 135 void Histo::Save() 137 { 136 { 138 if (!(fHistoActive || fNtupleActive)) { << 137 if(!(fHistoActive || fNtupleActive)) { return; } 139 return; << 140 } << 141 138 142 // Creating a tree mapped to a new hbook fil 139 // Creating a tree mapped to a new hbook file. 143 G4String nam = fHistName + "." + fHistType; 140 G4String nam = fHistName + "." + fHistType; 144 141 145 // Write histogram file 142 // Write histogram file 146 if (!fManager->Write()) { << 143 if(!fManager->Write()) { 147 G4Exception("Histo::Save()", "hist01", Fat << 144 G4Exception ("Histo::Save()", "hist01", FatalException, >> 145 "Cannot write ROOT file."); 148 } 146 } 149 if (fVerbose > 0) { << 147 if(fVerbose > 0) { 150 G4cout << "### Histo::Save: Histograms and 148 G4cout << "### Histo::Save: Histograms and Ntuples are saved" << G4endl; 151 } 149 } 152 if (fManager->CloseFile() && fVerbose > 0) { << 150 if(fManager->CloseFile() && fVerbose > 0) { 153 G4cout << " File is closed 151 G4cout << " File is closed" << G4endl; 154 } 152 } 155 fManager->Clear(); 153 fManager->Clear(); 156 } << 154 } 157 155 158 //....oooOO0OOooo........oooOO0OOooo........oo 156 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 159 157 160 void Histo::Add1D(const G4String& id, const G4 << 158 void Histo::Add1D(const G4String& id, const G4String& name, G4int nb, 161 G4double u) << 159 G4double x1, G4double x2, G4double u) 162 { 160 { 163 if (fVerbose > 0) { << 161 if(fVerbose > 0) { 164 G4cout << "Histo::Add1D: New histogram wil << 162 G4cout << "Histo::Add1D: New histogram will be booked: #" << id 165 << " " << x1 << " " << x2 << " " << 163 << " <" << name >> 164 << " " << nb << " " << x1 << " " << x2 << " " << u >> 165 << G4endl; 166 } 166 } 167 ++fNHisto; 167 ++fNHisto; 168 x1 /= u; 168 x1 /= u; 169 x2 /= u; 169 x2 /= u; 170 fActive.push_back(fDefaultAct); 170 fActive.push_back(fDefaultAct); 171 fBins.push_back(nb); 171 fBins.push_back(nb); 172 fXmin.push_back(x1); 172 fXmin.push_back(x1); 173 fXmax.push_back(x2); 173 fXmax.push_back(x2); 174 fUnit.push_back(u); 174 fUnit.push_back(u); 175 fIds.push_back(id); 175 fIds.push_back(id); 176 fTitles.push_back(name); 176 fTitles.push_back(name); 177 fHisto.push_back(-1); 177 fHisto.push_back(-1); 178 } 178 } 179 179 180 //....oooOO0OOooo........oooOO0OOooo........oo 180 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 181 181 182 void Histo::SetHisto1D(G4int i, G4int nb, G4do 182 void Histo::SetHisto1D(G4int i, G4int nb, G4double x1, G4double x2, G4double u) 183 { 183 { 184 if (i >= 0 && i < fNHisto) { << 184 if(i>=0 && i<fNHisto) { 185 if (fVerbose > 0) { << 185 if(fVerbose > 0) { 186 G4cout << "Histo::SetHisto1D: #" << i << << 186 G4cout << "Histo::SetHisto1D: #" << i >> 187 << " " << nb << " " << x1 << " " << x2 << " " << u 187 << G4endl; 188 << G4endl; 188 } 189 } 189 fBins[i] = nb; 190 fBins[i] = nb; 190 fXmin[i] = x1; 191 fXmin[i] = x1; 191 fXmax[i] = x2; 192 fXmax[i] = x2; 192 fUnit[i] = u; 193 fUnit[i] = u; 193 fActive[i] = true; 194 fActive[i] = true; 194 fHistoActive = true; 195 fHistoActive = true; 195 } << 196 } else { 196 else { << 197 G4cout << "Histo::SetHisto1D: WARNING! wrong histogram index " 197 G4cout << "Histo::SetHisto1D: WARNING! wro << 198 << i << G4endl; 198 } 199 } 199 } 200 } 200 201 201 //....oooOO0OOooo........oooOO0OOooo........oo 202 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 202 203 203 void Histo::Activate(G4int i, G4bool val) 204 void Histo::Activate(G4int i, G4bool val) 204 { 205 { 205 if (fVerbose > 1) { << 206 if(fVerbose > 1) { 206 G4cout << "Histo::Activate: Histogram: #" << 207 G4cout << "Histo::Activate: Histogram: #" << i << " " 207 } << 208 << val << G4endl; 208 if (i >= 0 && i < fNHisto) { << 209 } 209 fActive[i] = val; << 210 if(i>=0 && i<fNHisto) { 210 if (val) { << 211 fActive[i] = val; 211 fHistoActive = true; << 212 if(val) { fHistoActive = true; } 212 } << 213 } 213 } 214 } 214 } 215 215 216 //....oooOO0OOooo........oooOO0OOooo........oo 216 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 217 217 218 void Histo::Fill(G4int i, G4double x, G4double 218 void Histo::Fill(G4int i, G4double x, G4double w) 219 { 219 { 220 if (!fHistoActive) { << 220 if(!fHistoActive) { return; } 221 return; << 221 if(fVerbose > 1) { 222 } << 222 G4cout << "Histo::Fill: Histogram: #" << i << " at x= " << x 223 if (fVerbose > 1) { << 223 << " weight= " << w 224 G4cout << "Histo::Fill: Histogram: #" << i << 224 << G4endl; 225 } << 225 } 226 if (i >= 0 && i < fNHisto) { << 226 if(i>=0 && i<fNHisto) { 227 if (fActive[i]) { << 227 if(fActive[i]) { fManager->FillH1(fHisto[i], x/fUnit[i], w); } 228 fManager->FillH1(fHisto[i], x / fUnit[i] << 228 } else { 229 } << 230 } << 231 else { << 232 G4cout << "Histo::Fill: WARNING! wrong his 229 G4cout << "Histo::Fill: WARNING! wrong histogram index " << i << G4endl; 233 } 230 } 234 } 231 } 235 232 236 //....oooOO0OOooo........oooOO0OOooo........oo 233 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 237 234 238 void Histo::ScaleH1(G4int i, G4double x) 235 void Histo::ScaleH1(G4int i, G4double x) 239 { 236 { 240 if (!fHistoActive) { << 237 if(!fHistoActive) { return; } 241 return; << 238 if(fVerbose > 0) { 242 } << 239 G4cout << "Histo::Scale: Histogram: #" 243 if (fVerbose > 0) { << 240 << i << " by factor " << x << G4endl; 244 G4cout << "Histo::Scale: Histogram: #" << << 241 } 245 } << 242 if(i>=0 && i<fNHisto) { 246 if (i >= 0 && i < fNHisto) { << 243 if(fActive[i]) { fManager->GetH1(fHisto[i])->scale(x); } 247 if (fActive[i]) { << 244 } else { 248 fManager->GetH1(fHisto[i])->scale(x); << 249 } << 250 } << 251 else { << 252 G4cout << "Histo::Scale: WARNING! wrong hi 245 G4cout << "Histo::Scale: WARNING! wrong histogram index " << i << G4endl; 253 } 246 } 254 } 247 } 255 248 256 //....oooOO0OOooo........oooOO0OOooo........oo 249 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 257 250 258 void Histo::AddTuple(const G4String& w1) 251 void Histo::AddTuple(const G4String& w1) 259 { 252 { 260 fTupleTitle = w1; 253 fTupleTitle = w1; 261 } 254 } 262 255 263 //....oooOO0OOooo........oooOO0OOooo........oo 256 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 264 257 265 void Histo::AddTupleI(const G4String& w1) 258 void Histo::AddTupleI(const G4String& w1) 266 { 259 { 267 fNtupleActive = true; 260 fNtupleActive = true; 268 fNtupleI.push_back(w1); 261 fNtupleI.push_back(w1); 269 fTupleI.push_back(-1); 262 fTupleI.push_back(-1); 270 } 263 } 271 264 272 //....oooOO0OOooo........oooOO0OOooo........oo 265 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 273 266 274 void Histo::AddTupleF(const G4String& w1) 267 void Histo::AddTupleF(const G4String& w1) 275 { 268 { 276 fNtupleActive = true; 269 fNtupleActive = true; 277 fNtupleF.push_back(w1); 270 fNtupleF.push_back(w1); 278 fTupleF.push_back(-1); 271 fTupleF.push_back(-1); 279 } 272 } 280 273 281 //....oooOO0OOooo........oooOO0OOooo........oo 274 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 282 275 283 void Histo::AddTupleD(const G4String& w1) 276 void Histo::AddTupleD(const G4String& w1) 284 { 277 { 285 fNtupleActive = true; 278 fNtupleActive = true; 286 fNtupleD.push_back(w1); 279 fNtupleD.push_back(w1); 287 fTupleD.push_back(-1); 280 fTupleD.push_back(-1); 288 } 281 } 289 282 290 //....oooOO0OOooo........oooOO0OOooo........oo 283 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 291 284 292 void Histo::FillTupleI(G4int i, G4int x) 285 void Histo::FillTupleI(G4int i, G4int x) 293 { 286 { 294 if (!fNtupleActive) { << 287 if(!fNtupleActive) { return; } 295 return; << 296 } << 297 G4int n = fNtupleI.size(); 288 G4int n = fNtupleI.size(); 298 if (i >= 0 && i < n) { << 289 if(i >= 0 && i < n) { 299 if (fVerbose > 1) { << 290 if(fVerbose > 1) { 300 G4cout << "Histo::FillTupleI: i= " << i << 291 G4cout << "Histo::FillTupleI: i= " << i << " id= " << fTupleI[i] 301 << "> = " << x << G4endl; << 292 << " <" << fNtupleI[i] << "> = " << x << G4endl; 302 } << 293 } 303 fManager->FillNtupleIColumn(fTupleI[i], x) << 294 fManager->FillNtupleIColumn(fTupleI[i], x); 304 } << 295 } else { 305 else { << 296 G4cout << "Histo::FillTupleI: WARNING! wrong ntuple index " 306 G4cout << "Histo::FillTupleI: WARNING! wro << 297 << i << G4endl; 307 } 298 } 308 } 299 } 309 300 310 //....oooOO0OOooo........oooOO0OOooo........oo 301 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 311 302 312 void Histo::FillTupleF(G4int i, G4float x) 303 void Histo::FillTupleF(G4int i, G4float x) 313 { 304 { 314 if (!fNtupleActive) { << 305 if(!fNtupleActive) { return; } 315 return; << 316 } << 317 G4int n = fNtupleF.size(); 306 G4int n = fNtupleF.size(); 318 if (i >= 0 && i < n) { << 307 if(i >= 0 && i < n) { 319 if (fVerbose > 1) { << 308 if(fVerbose > 1) { 320 G4cout << "Histo::FillTupleF: i= " << i << 309 G4cout << "Histo::FillTupleF: i= " << i << " id= " << fTupleF[i] 321 << "> = " << x << G4endl; << 310 << " <" << fNtupleF[i] << "> = " << x << G4endl; 322 } << 311 } 323 fManager->FillNtupleFColumn(fTupleF[i], x) << 312 fManager->FillNtupleFColumn(fTupleF[i], x); 324 } << 313 } else { 325 else { << 314 G4cout << "Histo::FillTupleF: WARNING! wrong ntuple index " 326 G4cout << "Histo::FillTupleF: WARNING! wro << 315 << i << G4endl; 327 } 316 } 328 } 317 } 329 318 330 //....oooOO0OOooo........oooOO0OOooo........oo 319 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 331 320 332 void Histo::FillTupleD(G4int i, G4double x) 321 void Histo::FillTupleD(G4int i, G4double x) 333 { 322 { 334 if (!fNtupleActive) { << 323 if(!fNtupleActive) { return; } 335 return; << 336 } << 337 G4int n = fNtupleD.size(); 324 G4int n = fNtupleD.size(); 338 if (i >= 0 && i < n) { << 325 if(i >= 0 && i < n) { 339 if (fVerbose > 1) { << 326 if(fVerbose > 1) { 340 G4cout << "Histo::FillTupleD: i= " << i << 327 G4cout << "Histo::FillTupleD: i= " << i << " id= " << fTupleD[i] 341 << "> = " << x << G4endl; << 328 << " <" << fNtupleD[i] << "> = " << x << G4endl; 342 } << 329 } 343 fManager->FillNtupleDColumn(fTupleD[i], x) << 330 fManager->FillNtupleDColumn(fTupleD[i], x); 344 } << 331 } else { 345 else { << 332 G4cout << "Histo::FillTupleD: WARNING! wrong ntuple index " 346 G4cout << "Histo::FillTupleD: WARNING! wro << 333 << i << G4endl; 347 } 334 } 348 } 335 } 349 336 350 //....oooOO0OOooo........oooOO0OOooo........oo 337 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 351 338 352 void Histo::AddRow() 339 void Histo::AddRow() 353 { 340 { 354 if (!fNtupleActive) { << 341 if(!fNtupleActive) { return; } 355 return; << 356 } << 357 fManager->AddNtupleRow(); 342 fManager->AddNtupleRow(); 358 } << 343 } 359 344 360 //....oooOO0OOooo........oooOO0OOooo........oo 345 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 361 346 362 void Histo::SetFileName(const G4String& nam) << 347 void Histo::SetFileName(const G4String& nam) 363 { 348 { 364 fHistName = nam; 349 fHistName = nam; 365 fHistoActive = true; 350 fHistoActive = true; 366 } 351 } 367 352 368 //....oooOO0OOooo........oooOO0OOooo........oo 353 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... 369 354 370 void Histo::SetFileType(const G4String& nam) << 355 void Histo::SetFileType(const G4String& nam) 371 { 356 { 372 // format other than ROOT is not tested 357 // format other than ROOT is not tested 373 if (nam == "root" || nam == "ROOT") { << 358 if(nam == "root" || nam == "ROOT" ) { fHistType = "root"; } 374 fHistType = "root"; << 359 else if(nam == "xml" || nam == "XML") { fHistType = "xml"; } 375 } << 360 else if(nam == "ascii" || nam == "ASCII" || 376 else if (nam == "xml" || nam == "XML") { << 361 nam == "Csv" || nam == "csv" || nam == "CSV") 377 fHistType = "xml"; << 362 { fHistType = "ascii"; } 378 } << 379 else if (nam == "ascii" || nam == "ASCII" || << 380 fHistType = "ascii"; << 381 } << 382 } 363 } 383 364 384 //....oooOO0OOooo........oooOO0OOooo........oo 365 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... >> 366 385 367