40 if ( fgInstance == 0 ) {
66 <<
"G4RootAnalysisManager already exists."
67 <<
"Cannot create another instance.";
68 G4Exception(
"G4RootAnalysisManager::G4RootAnalysisManager()",
78 std::vector<tools::histo::h1d*>::iterator it;
79 for (it = fH1Vector.begin(); it != fH1Vector.end(); it++ ) {
83 std::vector<tools::histo::h2d*>::iterator it2;
84 for (it2 = fH2Vector.begin(); it2 != fH2Vector.end(); it2++ ) {
89 delete fNtupleBooking;
100G4bool G4RootAnalysisManager::CreateHistoDirectory()
104 fHistoDirectory = &(fFile->dir());
114 if ( ! fHistoDirectory ) {
118 G4Exception(
"G4RootAnalysisManager::CreateHistoDirectory()",
132G4bool G4RootAnalysisManager::CreateNtupleDirectory()
136 fNtupleDirectory = &(fFile->dir());
147 if ( ! fNtupleDirectory ) {
151 G4Exception(
"G4RootAnalysisManager::CreateNtupleDirectory()",
166void G4RootAnalysisManager::CreateNtupleFromBooking()
170 if ( fNtuple || (! fNtupleBooking) )
return;
176 fNtuple =
new tools::wroot::ntuple(*fNtupleDirectory, *fNtupleBooking);
178 if ( fNtupleBooking->m_columns.size() ) {
180 const std::vector<tools::ntuple_booking::col_t>& columns
181 = fNtupleBooking->m_columns;
182 std::vector<tools::ntuple_booking::col_t>::const_iterator it;
184 for ( it = columns.begin(); it!=columns.end(); ++it) {
185 if ( (*it).second == tools::_cid(
int(0) ) ) {
186 G4cout <<
"adding int " << fNtuple->find_column<
int>((*it).first) <<
G4endl;
187 fNtupleIColumnMap[index++] = fNtuple->find_column<
int>((*it).first);
189 else if( (*it).second == tools::_cid(
float(0) ) ) {
190 fNtupleFColumnMap[index++] = fNtuple->find_column<
float>((*it).first);
192 else if((*it).second== tools::_cid(
double(0))) {
193 fNtupleDColumnMap[index++] = fNtuple->find_column<
double>((*it).first);
198 <<
"Unsupported column type " << (*it).first;
199 G4Exception(
"G4RootAnalysisManager::CreateNtupleFromBooking()",
207tools::wroot::ntuple::column<int>*
208G4RootAnalysisManager::GetNtupleIColumn(
G4int id)
const
210 std::map<G4int, tools::wroot::ntuple::column<int>* >::const_iterator it
211 = fNtupleIColumnMap.find(
id);
212 if ( it == fNtupleIColumnMap.end() ) {
214 description <<
" " <<
"column " <<
id <<
" does not exist.";
215 G4Exception(
"G4RootAnalysisManager::GetNtupleIColumn()",
224tools::wroot::ntuple::column<float>*
225G4RootAnalysisManager::GetNtupleFColumn(
G4int id)
const
227 std::map<G4int, tools::wroot::ntuple::column<float>* >::const_iterator it
228 = fNtupleFColumnMap.find(
id);
229 if ( it == fNtupleFColumnMap.end() ) {
231 description <<
" " <<
"column " <<
id <<
" does not exist.";
232 G4Exception(
"G4RootAnalysisManager::GetNtupleFColumn()",
242tools::wroot::ntuple::column<double>*
243G4RootAnalysisManager::GetNtupleDColumn(
G4int id)
const
245 std::map<G4int, tools::wroot::ntuple::column<double>* >::const_iterator it
246 = fNtupleDColumnMap.find(
id);
247 if ( it == fNtupleDColumnMap.end() ) {
249 description <<
" " <<
"column " <<
id <<
" does not exist.";
250 G4Exception(
"G4RootAnalysisManager::GetNtupleDColumn()",
259G4bool G4RootAnalysisManager::Reset()
263 G4bool finalResult =
true;
265 std::vector<tools::histo::h1d*>::iterator it;
266 for (it = fH1Vector.begin(); it != fH1Vector.end(); it++ ) {
267 G4bool result = (*it)->reset();
268 if ( ! result ) finalResult =
false;
271 std::vector<tools::histo::h2d*>::iterator it2;
272 for (it2 = fH2Vector.begin(); it2 != fH2Vector.end(); it2++ ) {
273 G4bool result = (*it2)->reset();
274 if ( ! result ) finalResult =
false;
285void G4RootAnalysisManager::UpdateTitle(
G4String& title,
289 if ( fcnName !=
"none" ) { title +=
" "; title += fcnName; title +=
"("; }
290 if ( unitName !=
"none" ) { title +=
" ["; title += unitName; title +=
"]";}
291 if ( fcnName !=
"none" ) { title +=
")"; }
307 for (
G4int i=0; i<
G4int(fH1Vector.size()); ++i ) {
311 if ( ! info->
fAscii )
continue;
312 tools::histo::h1d* h1 = fH1Vector[i];
319 output <<
"\n 1D histogram " <<
id <<
": " << h1->title()
320 <<
"\n \n \t X \t\t Y" <<
G4endl;
322 for (
G4int j=0; j<
G4int(h1->axis().bins()); ++j) {
323 output <<
" " << j <<
"\t"
324 << h1->axis().bin_center(j) <<
"\t"
325 << h1->bin_height(i) <<
G4endl;
333tools::histo::h1d* G4RootAnalysisManager::GetH1InFunction(
G4int id,
335 G4bool onlyIfActive)
const
338 if ( index < 0 || index >=
G4int(fH1Vector.size()) ) {
340 G4String inFunction =
"G4RootAnalysisManager::";
341 inFunction += functionName;
343 description <<
" " <<
"histogram " <<
id <<
" does not exist.";
354 return fH1Vector[index];
358tools::histo::h2d* G4RootAnalysisManager::GetH2InFunction(
G4int id,
360 G4bool onlyIfActive)
const
363 if ( index < 0 || index >=
G4int(fH2Vector.size()) ) {
365 G4String inFunction =
"G4RootAnalysisManager::";
366 inFunction += functionName;
368 description <<
" " <<
"histogram " <<
id <<
" does not exist.";
379 return fH2Vector[index];
394 if ( name.find(
".") == std::string::npos ) {
405 if ( fFile )
delete fFile;
407 fFile =
new tools::wroot::file(std::cout, name);
408 if ( ! fFile->is_open() ) {
410 description <<
" " <<
"Cannot open file " << fileName;
417 if ( ! CreateHistoDirectory() )
return false;
418 if ( ! CreateNtupleDirectory() )
return false;
421 if ( fNtupleBooking && ( ! fNtuple ) )
422 CreateNtupleFromBooking();
440 for (
G4int i=0; i<
G4int(fH1Vector.size()); ++i ) {
445 tools::histo::h1d* h1 = fH1Vector[i];
451 = to(*fHistoDirectory,*h1,info->
fName);
454 description <<
" " <<
"saving histogram " << info->
fName <<
" failed";
462 for (
G4int i=0; i<
G4int(fH2Vector.size()); ++i ) {
467 tools::histo::h2d* h2 = fH2Vector[i];
473 = to(*fHistoDirectory,*h2,info->
fName);
476 description <<
" " <<
"saving histogram " << info->
fName <<
" failed";
489 G4bool result = fFile->write(n);
499 result = result && result2;
519 description <<
" " <<
"Resetting data failed";
546 G4int index = fH1Vector.size();
549 tools::histo::h1d* h1
550 =
new tools::histo::h1d(title, nbins, fcn(xmin), fcn(xmax));
555 UpdateTitle(axisTitle,unitName, fcnName);
556 h1->add_annotation(tools::histo::key_axis_x_title(), axisTitle);
558 fH1Vector.push_back(h1);
582 G4int index = fH2Vector.size();
587 tools::histo::h2d* h2
588 =
new tools::histo::h2d(title,
589 nxbins, xfcn(xmin), xfcn(xmax),
590 nybins, yfcn(ymin), yfcn(ymax));
596 UpdateTitle(xaxisTitle, xunitName, xfcnName);
597 UpdateTitle(yaxisTitle, yunitName, yfcnName);
598 h2->add_annotation(tools::histo::key_axis_x_title(), xaxisTitle);
599 h2->add_annotation(tools::histo::key_axis_y_title(), yaxisTitle);
601 fH2Vector.push_back(h2);
603 xunit, yunit, xfcn, yfcn);
619 tools::histo::h1d* h1d = GetH1InFunction(
id,
"SetH1",
false,
false);
620 if ( ! h1d )
return false;
630 h1d->configure(nbins, fcn(xmin), fcn(xmax));
642 UpdateTitle(axisTitle,unitName, fcnName);
643 h1d->add_annotation(tools::histo::key_axis_x_title(), axisTitle);
655 tools::histo::h2d* h2d = GetH2InFunction(
id,
"SetH2",
false,
false);
656 if ( ! h2d )
return false;
668 h2d->configure(nxbins, xfcn(xmin), xfcn(xmax),
669 nybins, yfcn(ymin), yfcn(ymax));
683 UpdateTitle(xaxisTitle, xunitName, xfcnName);
684 UpdateTitle(yaxisTitle, yunitName, yfcnName);
685 h2d->add_annotation(tools::histo::key_axis_x_title(), xaxisTitle);
686 h2d->add_annotation(tools::histo::key_axis_y_title(), yaxisTitle);
694 tools::histo::h1d* h1d = GetH1InFunction(
id,
"ScaleH1",
false,
false);
695 if ( ! h1d )
return false;
697 return h1d->scale(factor);
703 tools::histo::h2d* h2d = GetH2InFunction(
id,
"ScaleH2",
false,
false);
704 if ( ! h2d )
return false;
706 return h2d->scale(factor);
713 if ( fNtupleBooking ) {
716 <<
"Ntuple already exists. "
717 <<
"(Only one ntuple is currently supported.)";
718 G4Exception(
"G4RootAnalysisManager::CreateNtuple()",
724 if ( fFile && ( ! fNtupleDirectory ) ) {
725 if ( ! CreateNtupleDirectory() )
return;
734 fNtupleBooking =
new tools::ntuple_booking();
735 fNtupleBooking->m_name = name;
736 fNtupleBooking->m_title = title;
741 fNtuple =
new tools::wroot::ntuple(*fNtupleDirectory, name, title);
759 if ( ! fNtupleBooking ) {
762 <<
"Ntuple has to be created first. ";
763 G4Exception(
"G4RootAnalysisManager::CreateNtupleIColumn()",
769 G4int index = fNtupleBooking->m_columns.size();
770 fNtupleBooking->add_column<
int>(name);
774 tools::wroot::ntuple::column<int>* column
775 = fNtuple->create_column<
int>(name);
776 fNtupleIColumnMap[index] = column;
797 if ( ! fNtupleBooking ) {
800 <<
"Ntuple has to be created first. ";
801 G4Exception(
"G4RootAnalysisManager::CreateNtupleFColumn()",
807 G4int index = fNtupleBooking->m_columns.size();
808 fNtupleBooking->add_column<
float>(name);
812 tools::wroot::ntuple::column<float>* column
813 = fNtuple->create_column<
float>(name);
814 fNtupleFColumnMap[index] = column;
836 if ( ! fNtupleBooking ) {
839 <<
"Ntuple has to be created first. ";
840 G4Exception(
"G4RootAnalysisManager::CreateNtupleDColumn()",
846 G4int index = fNtupleBooking->m_columns.size();
847 fNtupleBooking->add_column<
double>(name);
851 tools::wroot::ntuple::column<double>* column
852 = fNtuple->create_column<
double>(name);
853 fNtupleDColumnMap[index] = column;
875 tools::histo::h1d* h1d = GetH1InFunction(
id,
"FillH1",
true,
false);
876 if ( ! h1d )
return false;
884 h1d->fill(info->
fXFcn(value/info->
fXUnit), weight);
888 description <<
" id " <<
id <<
" value " << value;
900 tools::histo::h2d* h2d = GetH2InFunction(
id,
"FillH2",
true,
false);
901 if ( ! h2d )
return false;
911 description <<
" id " <<
id
912 <<
" xvalue " << xvalue <<
" yvalue " << yvalue;
922 tools::wroot::ntuple::column<int>* column = GetNtupleIColumn(
id);
925 description <<
" " <<
"column " <<
id <<
" does not exist.";
926 G4Exception(
"G4RootAnalysisManager::FillNtupleIColumn()",
935 description <<
" id " <<
id <<
" value " << value;
944 tools::wroot::ntuple::column<float>* column = GetNtupleFColumn(
id);
947 description <<
" " <<
"column " <<
id <<
" does not exist.";
948 G4Exception(
"G4RootAnalysisManager::FillNtupleFColumn()",
957 description <<
" id " <<
id <<
" value " << value;
966 tools::wroot::ntuple::column<double>* column = GetNtupleDColumn(
id);
969 description <<
" " <<
"column " <<
id <<
" does not exist.";
970 G4Exception(
"G4RootAnalysisManager::FillNtupleDColumn()",
979 description <<
" id " <<
id <<
" value " << value;
996 description <<
" " <<
"ntuple does not exist. ";
997 G4Exception(
"G4RootAnalysisManager::AddNtupleRow()",
1002 G4bool result =fNtuple->add_row();
1005 description <<
" " <<
"adding row has failed.";
1006 G4Exception(
"G4RootAnalysisManager::AddNtupleRow()",
1019 G4bool onlyIfActive)
const
1021 return GetH1InFunction(
id,
"GetH1", warn, onlyIfActive);
1026 G4bool onlyIfActive)
const
1028 return GetH2InFunction(
id,
"GetH2", warn, onlyIfActive);
1034 std::map<G4String, G4int>::const_iterator it = fH1NameIdMap.find(name);
1035 if ( it == fH1NameIdMap.end() ) {
1037 G4String inFunction =
"G4RootAnalysisManager::GetH1Id";
1039 description <<
" " <<
"histogram " << name <<
" does not exist.";
1050 std::map<G4String, G4int>::const_iterator it = fH2NameIdMap.find(name);
1051 if ( it == fH2NameIdMap.end() ) {
1053 G4String inFunction =
"G4RootAnalysisManager::GetH2Id";
1055 description <<
" " <<
"histogram " << name <<
" does not exist.";
1072 tools::histo::h1d* h1d = GetH1InFunction(
id,
"GetH1Nbins");
1073 if ( ! h1d )
return 0;
1075 return h1d->axis().bins();
1083 tools::histo::h1d* h1d = GetH1InFunction(
id,
"GetH1Xmin");
1084 if ( ! h1d )
return 0;
1087 return info->
fXFcn(h1d->axis().lower_edge()*info->
fXUnit);
1093 tools::histo::h1d* h1d = GetH1InFunction(
id,
"GetH1Xmax");
1094 if ( ! h1d )
return 0;
1097 return info->
fXFcn(h1d->axis().upper_edge()*info->
fXUnit);
1103 tools::histo::h1d* h1d = GetH1InFunction(
id,
"GetH1XWidth",
true,
false);
1104 if ( ! h1d )
return 0;
1106 G4int nbins = h1d->axis().bins();
1109 description <<
" nbins = 0 (for h1 id = " <<
id <<
").";
1116 return ( info->
fXFcn(h1d->axis().upper_edge())
1117 - info->
fXFcn(h1d->axis().lower_edge()))*info->
fXUnit/nbins;
1123 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2NXbins");
1124 if ( ! h2d )
return 0;
1126 return h2d->axis_x().bins();
1134 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2Xmin");
1135 if ( ! h2d )
return 0;
1138 return info->
fXFcn(h2d->axis_x().lower_edge()*info->
fXUnit);
1144 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2Xmax");
1145 if ( ! h2d )
return 0;
1148 return info->
fXFcn(h2d->axis_x().upper_edge()*info->
fXUnit);
1154 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2XWidth",
true,
false);
1155 if ( ! h2d )
return 0;
1157 G4int nbins = h2d->axis_x().bins();
1160 description <<
" nbins = 0 (for h1 id = " <<
id <<
").";
1167 return ( info->
fXFcn(h2d->axis_x().upper_edge())
1168 - info->
fXFcn(h2d->axis_x().lower_edge()))*info->
fXUnit/nbins;
1174 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2NYbins");
1175 if ( ! h2d )
return 0;
1177 return h2d->axis_y().bins();
1185 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2Ymin");
1186 if ( ! h2d )
return 0;
1189 return info->
fYFcn(h2d->axis_y().lower_edge()*info->
fYUnit);
1195 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2Ymax");
1196 if ( ! h2d )
return 0;
1199 return info->
fYFcn(h2d->axis_y().upper_edge()*info->
fYUnit);
1205 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2YWidth",
true,
false);
1206 if ( ! h2d )
return 0;
1208 G4int nbins = h2d->axis_y().bins();
1211 description <<
" nbins = 0 (for h1 id = " <<
id <<
").";
1218 return ( info->
fYFcn(h2d->axis_y().upper_edge())
1219 - info->
fYFcn(h2d->axis_y().lower_edge()))*info->
fYUnit/nbins;
1225 tools::histo::h1d* h1d = GetH1InFunction(
id,
"SetH1Title");
1226 if ( ! h1d )
return false;
1228 return h1d->set_title(title);
1234 tools::histo::h1d* h1d = GetH1InFunction(
id,
"SetH1XAxisTitle");
1235 if ( ! h1d )
return false;
1237 h1d->add_annotation(tools::histo::key_axis_x_title(), title);
1244 tools::histo::h1d* h1d = GetH1InFunction(
id,
"SetH1YAxisTitle");
1245 if ( ! h1d )
return false;
1247 h1d->add_annotation(tools::histo::key_axis_y_title(), title);
1254 tools::histo::h2d* h2d = GetH2InFunction(
id,
"SetH2Title");
1255 if ( ! h2d )
return false;
1257 return h2d->set_title(title);
1263 tools::histo::h2d* h2d = GetH2InFunction(
id,
"SetH2XAxisTitle");
1264 if ( ! h2d )
return false;
1266 h2d->add_annotation(tools::histo::key_axis_x_title(), title);
1273 tools::histo::h2d* h2d = GetH2InFunction(
id,
"SetH2YAxisTitle");
1274 if ( ! h2d )
return false;
1276 h2d->add_annotation(tools::histo::key_axis_x_title(), title);
1283 tools::histo::h2d* h2d = GetH2InFunction(
id,
"SetH2ZAxisTitle");
1284 if ( ! h2d )
return false;
1286 h2d->add_annotation(tools::histo::key_axis_z_title(), title);
1293 tools::histo::h1d* h1d = GetH1InFunction(
id,
"GetH1Title");
1294 if ( ! h1d )
return "";
1296 return h1d->title();
1303 tools::histo::h1d* h1d = GetH1InFunction(
id,
"GetH1XAxisTitle");
1304 if ( ! h1d )
return "";
1307 G4bool result = h1d->annotation(tools::histo::key_axis_x_title(), title);
1310 description <<
" Failed to get x_axis title for h1 id = " <<
id <<
").";
1311 G4Exception(
"G4RootAnalysisManager::GetH1XAxisTitle",
1322 tools::histo::h1d* h1d = GetH1InFunction(
id,
"GetH1YAxisTitle");
1323 if ( ! h1d )
return "";
1326 G4bool result = h1d->annotation(tools::histo::key_axis_y_title(), title);
1329 description <<
" Failed to get y_axis title for h1 id = " <<
id <<
").";
1330 G4Exception(
"G4RootAnalysisManager::GetH1YAxisTitle",
1341 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2Title");
1342 if ( ! h2d )
return "";
1344 return h2d->title();
1350 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2XAxisTitle");
1351 if ( ! h2d )
return "";
1354 G4bool result = h2d->annotation(tools::histo::key_axis_x_title(), title);
1357 description <<
" Failed to get x_axis title for h2 id = " <<
id <<
").";
1358 G4Exception(
"G4RootAnalysisManager::GetH2XAxisTitle",
1369 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2YAxisTitle");
1370 if ( ! h2d )
return "";
1373 G4bool result = h2d->annotation(tools::histo::key_axis_y_title(), title);
1376 description <<
" Failed to get y_axis title for h2 id = " <<
id <<
").";
1377 G4Exception(
"G4RootAnalysisManager::GetH2YAxisTitle",
1388 tools::histo::h2d* h2d = GetH2InFunction(
id,
"GetH2ZAxisTitle");
1389 if ( ! h2d )
return "";
1392 G4bool result = h2d->annotation(tools::histo::key_axis_z_title(), title);
1395 description <<
" Failed to get z_axis title for h2 id = " <<
id <<
").";
1396 G4Exception(
"G4RootAnalysisManager::GetH2ZAxisTitle",
G4double(* G4Fcn)(G4double)
G4DLLIMPORT std::ostream G4cout
void Message(const G4String &action, const G4String &object, const G4String &objectName, G4bool success=true)
virtual G4bool SetH2(G4int id, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none")
virtual G4String GetH1XAxisTitle(G4int id) const
virtual tools::histo::h1d * GetH1(G4int id, G4bool warn=true, G4bool onlyIfActive=true) const
virtual G4int CreateNtupleIColumn(const G4String &name)
virtual G4int CreateNtupleDColumn(const G4String &name)
virtual G4int GetH2Nxbins(G4int id) const
virtual G4String GetH2ZAxisTitle(G4int id) const
virtual G4int CreateH2(const G4String &name, const G4String &title, G4int nxbins, G4double xmin, G4double xmax, G4int nybins, G4double ymin, G4double ymax, const G4String &xunitName="none", const G4String &yunitName="none", const G4String &xfcnName="none", const G4String &yfcnName="none")
virtual G4bool SetH1(G4int id, G4int nbins, G4double xmin, G4double xmax, const G4String &unitName="none", const G4String &fcnName="none")
virtual G4String GetH2YAxisTitle(G4int id) const
virtual G4bool SetH1XAxisTitle(G4int id, const G4String &title)
virtual G4bool SetH1Title(G4int id, const G4String &title)
virtual G4bool FillH1(G4int id, G4double value, G4double weight=1.0)
virtual G4double GetH2Ymax(G4int id) const
virtual G4bool FillNtupleFColumn(G4int id, G4float value)
virtual G4bool SetH2YAxisTitle(G4int id, const G4String &title)
virtual void CreateNtuple(const G4String &name, const G4String &title)
virtual tools::wroot::ntuple * GetNtuple() const
static G4RootAnalysisManager * Instance()
virtual G4bool CloseFile()
virtual G4int CreateH1(const G4String &name, const G4String &title, G4int nbins, G4double xmin, G4double xmax, const G4String &unitName="none", const G4String &fcnName="none")
virtual G4String GetH1Title(G4int id) const
virtual G4bool SetH2Title(G4int id, const G4String &title)
virtual void FinishNtuple()
virtual ~G4RootAnalysisManager()
virtual G4String GetH2XAxisTitle(G4int id) const
virtual G4double GetH2Ymin(G4int id) const
virtual G4String GetH1YAxisTitle(G4int id) const
virtual G4int GetH1Nbins(G4int id) const
virtual G4int CreateNtupleFColumn(const G4String &name)
virtual G4double GetH2XWidth(G4int id) const
virtual G4bool ScaleH1(G4int id, G4double factor)
virtual tools::histo::h2d * GetH2(G4int id, G4bool warn=true, G4bool onlyIfActive=true) const
virtual G4bool SetH2ZAxisTitle(G4int id, const G4String &title)
virtual G4bool AddNtupleRow()
virtual G4String GetH2Title(G4int id) const
virtual G4double GetH2Xmax(G4int id) const
virtual G4double GetH2Xmin(G4int id) const
virtual G4double GetH1Xmax(G4int id) const
virtual G4double GetH1Xmin(G4int id) const
virtual G4bool ScaleH2(G4int id, G4double factor)
virtual G4bool OpenFile()
virtual G4int GetH2Id(const G4String &name, G4bool warn=true) const
virtual G4bool FillH2(G4int id, G4double xvalue, G4double yvalue, G4double weight=1.0)
virtual G4bool WriteOnAscii(std::ofstream &output)
virtual G4double GetH1Width(G4int id) const
virtual G4int GetH2Nybins(G4int id) const
virtual G4bool SetH2XAxisTitle(G4int id, const G4String &title)
virtual G4bool FillNtupleDColumn(G4int id, G4double value)
virtual G4bool SetH1YAxisTitle(G4int id, const G4String &title)
virtual G4bool FillNtupleIColumn(G4int id, G4int value)
virtual G4double GetH2YWidth(G4int id) const
virtual G4int GetH1Id(const G4String &name, G4bool warn=true) const
G4String & append(const G4String &)
G4double GetUnitValue(const G4String &unit) const
G4bool GetActivation() const
void AddH1Information(const G4String &name, const G4String &unitName, const G4String &fcnName, G4double unit, G4Fcn fx)
G4int fFirstNtupleColumnId
G4AnalysisVerbose * fpVerboseL4
void AddH2Information(const G4String &name, const G4String &xunitName, const G4String &yunitName, const G4String &xfcnName, const G4String &yfcnName, G4double xunit, G4double yunit, G4Fcn fx, G4Fcn fy)
G4bool fLockFirstNtupleColumnId
G4bool fLockNtupleDirectoryName
G4AnalysisVerbose * fpVerboseL2
G4HnInformation * GetH2Information(G4int id) const
G4String fHistoDirectoryName
G4HnInformation * GetInformation(ObjectType type, G4int id) const
G4AnalysisVerbose * fpVerboseL3
void SetActivation(G4bool activation)
G4HnInformation * GetH1Information(G4int id) const
G4bool fLockHistoDirectoryName
G4String fNtupleDirectoryName
G4AnalysisVerbose * fpVerboseL1
G4String GetFileType() const
virtual G4String GetFullFileName() const
G4Fcn GetFunction(const G4String &fcnName) const
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)
std::ostringstream G4ExceptionDescription