|
[yoda-svn] r526 - in trunk: include/YODA srcblackhole at projects.hepforge.org blackhole at projects.hepforge.orgMon Sep 17 10:24:29 BST 2012
Author: dgrell Date: Mon Sep 17 10:24:28 2012 New Revision: 526 Log: WriterAIDA now directly diffable to Rivet-AIDA output Modified: trunk/include/YODA/WriterAIDA.h trunk/src/WriterAIDA.cc Modified: trunk/include/YODA/WriterAIDA.h ============================================================================== --- trunk/include/YODA/WriterAIDA.h Thu Aug 9 15:23:21 2012 (r525) +++ trunk/include/YODA/WriterAIDA.h Mon Sep 17 10:24:28 2012 (r526) @@ -23,7 +23,8 @@ /// Singleton creation function static Writer& create() { static WriterAIDA _instance; - _instance.setPrecision(6); + // Unused anyway; but if used, does not work in yoda2aida + // _instance.setPrecision(6); return _instance; } Modified: trunk/src/WriterAIDA.cc ============================================================================== --- trunk/src/WriterAIDA.cc Thu Aug 9 15:23:21 2012 (r525) +++ trunk/src/WriterAIDA.cc Mon Sep 17 10:24:28 2012 (r526) @@ -62,7 +62,7 @@ void WriterAIDA::writeScatter2D(std::ostream& os, const Scatter2D& s) { ios_base::fmtflags oldflags = os.flags(); - const int precision = 7; + const int precision = 8; os << scientific << showpoint << setprecision(precision); string name = ""; @@ -72,9 +72,9 @@ name = s.path().substr(slashpos+1, s.path().length() - slashpos - 1); path = s.path().substr(0, slashpos); } - os << " <dataPointSet name=\"" << Utils::encodeForXML(name) << "\"" - << " title=\"" << Utils::encodeForXML(s.title()) << "\"" - << " path=\"" << Utils::encodeForXML(path) << "\">\n"; + os << " <dataPointSet name=\"" << Utils::encodeForXML(name) << "\"\n" + << " title=\"" << Utils::encodeForXML(s.title()) << "\"" + << " path=\"" << Utils::encodeForXML(path) << "\" dimension=\"2\">\n"; os << " <dimension dim=\"0\" title=\"\" />\n"; os << " <dimension dim=\"1\" title=\"\" />\n"; os << " <annotation>\n"; @@ -90,9 +90,13 @@ foreach (Point2D pt, s.points()) { os << " <dataPoint>\n"; os << " <measurement value=\"" << pt.x() - << "\" errorMinus=\"" << pt.xErrMinus() << "\" errorPlus=\"" << pt.xErrPlus() << "\"/>\n"; + << "\" errorPlus=\"" << pt.xErrPlus() + << "\" errorMinus=\"" << pt.xErrMinus() + << "\"/>\n"; os << " <measurement value=\"" << pt.y() - << "\" errorMinus=\"" << pt.yErrMinus() << "\" errorPlus=\"" << pt.yErrPlus() << "\"/>\n"; + << "\" errorPlus=\"" << pt.yErrPlus() + << "\" errorMinus=\"" << pt.yErrMinus() + << "\"/>\n"; os << " </dataPoint>\n"; } os << " </dataPointSet>\n";
More information about the yoda-svn mailing list |