User Tools

Site Tools


root:pythonrootconstructors

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
root:pythonrootconstructors [2009/06/08 14:24] – created abuechleroot:pythonrootconstructors [2009/07/25 13:22] (current) decianm
Line 1: Line 1:
-How use a ROOT constructor which needs pointers as arguments. \\+====== How use a ROOT constructor which needs pointers as arguments in python====== 
 For example to create a histogram with variable bin width, the constructor needs a pointer to the array of the lowEdges (xbins). For example to create a histogram with variable bin width, the constructor needs a pointer to the array of the lowEdges (xbins).
 <code> <code>
Line 5: Line 6:
 </code> </code>
  
-To make Root understand the pointer use the **array** class.+To make pyRoot understand the pointer use the **array** class.
 <code> <code>
 from ROOT import * from ROOT import *
Line 12: Line 13:
 binLowE = [2,4,9,15,20,22] binLowE = [2,4,9,15,20,22]
 uniformTau = TH1D("uniformTau","",5,array('d',binLowE)) uniformTau = TH1D("uniformTau","",5,array('d',binLowE))
- 
 </code> </code>
root/pythonrootconstructors.txt · Last modified: 2009/07/25 13:22 by decianm