25 namespace GLTutorials {
53 using namespace ROOT::GLTutorials;
55 Double_t s1x = 0., s1y = 0., s1z = 0.;
56 Double_t s2x = 0., s2y = 0., s2z = 0.;
57 Double_t s3x = 0., s3y = 0., s3z = 0.;
60 TCanvas *
c1 =
new TCanvas(
"parallel coors",
"parallel coords", 0, 0, 900, 1000);
62 TNtuple *
const nt =
new TNtuple(
"nt",
"Demo ntuple",
"x:y:z:u:v:w:a:b:c");
64 for (
Int_t i = 0; i < 1500; ++i) {
73 nt->Fill(s1x, s1y, s1z, s2x, s2y, s2z,
r7,
r8,
r9);
79 nt->Fill(s2x - 1, s2y - 1, s2z, s1x + .5, s1y + .5, s1z + .5,
r7,
r8,
r9);
85 nt->Fill(s1x + 1, s1y + 1, s1z + 1, s3x - 2, s3y - 2, s3z - 2,
r7,
r8,
r9);
95 nt->Draw(
"x:y:z:u:v:w:a:b:c",
"",
"para");
97 assert(para1 != 0 &&
"parallelcoordtrans, 'ParaCoord' is null");
99 para1->SetLineColor(25);
101 pcv->SetHistogramHeight(0.);
104 pcv->SetHistogramHeight(0.);
107 pcv->SetHistogramHeight(0.);
110 pcv->SetHistogramHeight(0.);
113 pcv->SetHistogramHeight(0.);
116 pcv->SetHistogramHeight(0.);
119 pcv->SetHistogramHeight(0.);
122 pcv->SetHistogramHeight(0.);
125 pcv->SetHistogramHeight(0.);
131 assert(col26 != 0 &&
"parallelcoordtrans, color with index 26 not found");
133 col26->SetAlpha(0.01);
136 nt->Draw(
"x:y:z:u:v:w:a:b:c",
"",
"para");
138 assert(para2 != 0 &&
"parallelcoordtrans, 'ParaCoord' is null");
140 para2->SetLineColor(26);
143 pcv->SetHistogramHeight(0.);
146 pcv->SetHistogramHeight(0.);
149 pcv->SetHistogramHeight(0.);
152 pcv->SetHistogramHeight(0.);
155 pcv->SetHistogramHeight(0.);
158 pcv->SetHistogramHeight(0.);
161 pcv->SetHistogramHeight(0.);
164 pcv->SetHistogramHeight(0.);
167 pcv->SetHistogramHeight(0.);
void generate_random(Int_t i)
virtual void Rannor(Float_t &a, Float_t &b)
Return 2 numbers distributed following a gaussian with mean=0 and sigma=1.
virtual Double_t Rndm(Int_t i=0)
Machine independent random number generator.
R__EXTERN TStyle * gStyle
This is the base class for the ROOT Random number generators.
void parallelcoordtrans()
void SetCanvasPreferGL(Bool_t prefer=kTRUE)
The color creation and management class.
virtual void Sphere(Double_t &x, Double_t &y, Double_t &z, Double_t r)
Generates random vectors, uniformly distributed over the surface of a sphere of given radius...
Parallel Coordinates class.
virtual TObject * FindObject(const char *name) const
Must be redefined in derived classes.