In the radioactivedecay example, there are two ways provided to initialize the histogram parameters (e.g., nbin, vmin, vmax). One is to use analysisManager->CreateH1, and the other is to use /analysis/h1/set command. I thought they are equivalent, but they seem to be executed along different routes. Here is the observation.
- When I initialize the histogram using the following command and execute ‘/run/beamOn’, the vmax of the histogram are set at 1.5e6.
analysisManager->CreateH1(1, “energy spectrum (%): e+ e-”, 100, 0, 1500, “keV”);
In this case, vmax seems to be initialized using the unit provided (keV), which makes sense.
- When I run the following command, the vmax is set at 1.5e3.
/analysis/h1/set 1 150 0. 1500 keV
This probably sets the vmax using the default unit (eV). Not sure why.