Show how to shade an area between two graphs
void graphShade() {
"A Simple Graph Example",200,10,700,500);
c1->DrawFrame(0,0,2.2,12);
ymax[i] = 10*sin(
x[i]+0.2);
ymin[i] = 8*sin(
x[i]+0.1);
}
}
}
virtual void SetFillColor(Color_t fcolor)
Set the fill area color.
virtual void SetFillStyle(Style_t fstyle)
Set the fill area style.
virtual void SetLineWidth(Width_t lwidth)
Set the line width.
virtual void SetMarkerColor(Color_t mcolor=1)
Set the marker color.
virtual void SetMarkerStyle(Style_t mstyle=1)
Set the marker style.
A TGraph is an object made of two arrays X and Y with npoints each.
virtual void SetPoint(Int_t i, Double_t x, Double_t y)
Set x and y values for point number i.
void Draw(Option_t *chopt="") override
Draw this graph with its current attributes.
- Author
- Rene Brun
Definition in file graphShade.C.