13.2.10. Macro “dataserverGeyserRank.C”
13.2.10.1. Objective
This part shows the complete code used to produce the console display in Computing the ranking.
13.2.10.2. Macro Uranie
TDataServer *tdsGeyser =new TDataServer("geyser","poet");
tdsGeyser->fileDataRead("geyser.dat");
tdsGeyser->computeRank("x1");
tdsGeyser->computeStatistic("Rk_x1");
cout<<"NPatterns="<<tdsGeyser->getNPatterns()<<"; min(Rk_x1)= "
<<tdsGeyser->getAttribute("Rk_x1")->getMinimum()
<<"; max(Rk_x1)= "<<tdsGeyser->getAttribute("Rk_x1")->getMaximum()<<endl;
13.2.10.3. Console
This macro should result in this output in console:
NPatterns=272; min(Rk_x1)= 1; max(Rk_x1)= 272