|
[Rivet] ratio plotAndy Buckley andy.buckley at ed.ac.ukSun Jan 2 16:47:16 GMT 2011
On 02/01/11 03:57, Sercan Sen wrote: > > Hi, > > There is a plot at the attachment. > > I would like to get the ratios "r1 = a / b" and > "r2 = c / d" and plot r1, r2 on the RATIO plot. > > Is there an option for this in make-plots script ? > > It's easy to do it in ROOT but for some reasons > I would like to do it in Rivet. > > // in ROOT: .. first, plot a and b in a canvas... and create a TPad for > the ratio plot.. > TPad *pad = new TPad("pad","pad",0,0,1,0.3); > pad->SetTopMargin(0); > pad->Draw(); > pad->cd(); > a->Sumw2(); > a->SetStats(0); > a->Divide(b); > a->Draw("ep"); > ... Hi Sercan, Sorry, there's no built-in way to do this with make-plots at the moment: it's meant to be a script to cover a set of common tasks, not a programmable plotting system like ROOT. You can convert the AIDA files to ROOT TGraphs with the aida2root script, and plot what you want that way. As a long-term. low priority goal, I would like to split the core code out of make-plots to make a nice Python module for programmatic plotting. Any ideas or contributions to that are exceedingly welcome, but it's at the no-code stage now, just a few ideas. Andy -- Dr Andy Buckley SUPA Advanced Research Fellow Particle Physics Experiment Group, University of Edinburgh The University of Edinburgh is a charitable body, registered in Scotland, with registration number SC005336.
More information about the Rivet mailing list |