P1D data holder with systematical errors
Code: "p1d_systematics1.py". Programming language: Python DMelt Version 1. Last modified: 12/08/2015. License: Pro
https://datamelt.org/code/cache/p1d_systematics1_32.py
To run this script using the DMelt IDE, copy the above URL link to the menu [File]→[Read script from URL] of the DMelt IDE.



from java.awt import Color
from java.util import Random
from jhplot  import * 

c1 = HPlot("Canvas")
c1.visible()
c1.setRange(5,25,70,120)
c1.setGTitle("Systematical uncertainties", Color.blue) #put title
c1.viewHisto(0) # make sure starts from 0

# fill first data set
# this is a default measurement
p1= P1D("Central")
p1.setColor(Color.blue)
p1.add(12,100)
p1.add(22,80)


p2= P1D("Lower")
p2.add(10,90)
p2.add(20,75)
c1.draw(p2)

p3= P1D("Upper")
p3.add(10,110)
p3.add(20,96)
c1.draw(p3)

p0=p1.operErrSys("Data",1,p2,p3)
p0.setErrSys(1)
p0.setPenWidthErrSys(2)
c1.draw(p0)

You see the box below because you did not login.