Hi,
I’m trying the nice new feature of PLC and PMC draw options, but my below simple pyroot code does not work well:
#!/usr/bin/env python
from ROOT import *
h1 = TH1F("h1","h1",50,-10,10)
h2 = TH1F("h2","h2",50,-10,10)
h3 = TH1F("h3","h3",50,-10,10)
h4 = TH1F("h4","h4",50,-10,10)
h1.FillRandom('gaus',1500)
h2.FillRandom('gaus',1000)
h3.FillRandom('gaus',500)
h4.FillRandom('gaus',200)
h2.SetMarkerStyle(20)
h1.SetMarkerStyle(25)
h3.SetMarkerStyle(26)
opt='E'
h1.Draw(opt+'PLC PMC')
h2.Draw(opt+'SAME PLC PMC')
h3.Draw(opt+'SAME PLC PMC')
h4.Draw('SAME')
gPad.BuildLegend();
gPad.Update()
x = raw_input("wait:")
The styles change when the canvas is clicked. And, the 1st one and last one always have the same color?
Also, the histograms are not visible on the Canvas if I use opt=’’.
I’m not sure if this is due to my configuration. Any thing obviously wrong in this code? Thanks!