13.3.6. Macro “dataserverLoadASCIIFileIonosphere.py”
13.3.6.1. Objective
The objective of this macro is to load the ASCII data file ionosphere.dat which defines 34 input
variables and one output variable y and applies visualisation on one of these variables. The data
file ionosphere.dat is in the “Salome-table” format of Uranie but is not shown for convenience.
13.3.6.2. Macro Uranie
"""
Example of data loading for Ionosphere dataset
"""
from URANIE import DataServer
import ROOT
tds = DataServer.TDataServer()
tds.fileDataRead("ionosphere.dat")
tds.getAttribute("x28").SetTitle("#Delta P_{e}^{F_{iso}}")
# Graph
Canvas = ROOT.TCanvas("c1", "Graph for the Macro loadASCIIFileIonosphere",
5, 64, 1270, 667)
tds.draw("x28")
The TDataServer is filled with ionosphere.dat with the fileDataRead method
tds.fileDataRead("ionosphere.dat")
A new title is set for the variable x28
tds.getAttribute("x28").SetTitle("#Delta P_{e}^{F_{iso}}")
This variable is then drawn with its new title
tds.draw("x28")
13.3.6.3. Graph
Figure 13.5 Graph of the macro
"dataserverLoadASCIIFileIonosphere.py"