<div dir="ltr"><div><div>Hi Christian,<br><br></div>What I usually do in this situation is to split the .yoda file into several files, then call rivet-cmphistos or rivet-mkhtml on all files at once. I've put a small skeleton of python code in the post script. Hopefully it is clear what needs to be filled in by you, but please let me know if there are questions.<br><br></div>Chris<br><br><span style="font-family:monospace,monospace">import yoda<br>from sys import stdout, argv<br><br># dictionary of paths (keys) and analysis objects (values)<br>aodict = yoda.core.read(argv[0], True)<br><br>yfiledict = {}<br>for k, ao in aodict.iteritems():<br>    # TODO<br>    # decide which file (fname) this analysis object goes into<br>    # alter the analysis object path according to the plots you want to make<br>    # (objects with the same path will be plotted together by rivet-cmphistos)<br><br>    if fname in yfiledict:<br>        yfiledict[fname].append(ao)<br>    else:<br>        yfiledict[fname] = [ao]<br><br>    continue<br><br># loop over outfiles and store objects<br>for fname, aos in yfiledict.iteritems():<br>    yoda.write(aos, fname)</span><br><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Mar 6, 2015 at 10:18 PM, Christian Johnson <span dir="ltr"><<a href="mailto:christian.johnson@cern.ch" target="_blank">christian.johnson@cern.ch</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Rivet team,<br>
<br>
I have a feature request. There may already be a method for this, if so then please let me know.<br>
<br>
I have run into a few occasions where it is useful to compare several plots from the same yoda file (e.g. control region distribution comparison, etc…) on the same canvas. I have not been able to figure out a simple way to do this other than building the “*.dat” file myself and then using make-plots. I am sure there is an easier way using the YODA framework.<br>
<br>
Cheers,<br>
Christian Johnson<br>_______________________________________________<br>
Rivet mailing list<br>
<a href="mailto:Rivet@projects.hepforge.org" target="_blank">Rivet@projects.hepforge.org</a><br>
<a href="https://www.hepforge.org/lists/listinfo/rivet" target="_blank">https://www.hepforge.org/lists/listinfo/rivet</a><br></blockquote></div><br></div></div>