|
[Rivet] Scaling histogramsAndy Buckley andy.buckley at ed.ac.ukWed Sep 5 19:54:56 BST 2012
Does the --multiply flag to rivet-rescale do what you want? (see rivet-rescale --help) If that's not what you need, then probably it's best to access the histograms programmatically via the "lighthisto" Python module, with something like import lighthisto histodict = lighthisto.Histo.fromAIDA("mydata.aida") ... To get interface info for lighthisto, call the following at a Python prompt: >>> import lighthisto >>> help(lighthisto) The major objects are the Histo and Bin, for which you can get info with >>> help(lighthisto.Histo) >>> help(lighthisto.Bin) An example usage relevant for you would be for b in xrange(myhisto.numBins()): #print myhisto.getBin(b).val myhisto.getBin(b).val *= 0.67 Hope that helps, Andy On 05/09/12 18:26, Jennifer Kieselmann wrote: > Hey all, > > how can I scale histograms with the rivet-rescale only by a constant > factor? I need to multiply the values by 0.67. From the help I didn't > really find out how this is possible. > > Can you help me? > > Thanks a lot > Jennifer > _______________________________________________ > Rivet mailing list > Rivet at projects.hepforge.org > http://www.hepforge.org/lists/listinfo/rivet > -- Dr Andy Buckley, SUPA Advanced Research Fellow Particle Physics Expt 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 |