Demonstrates how to plot calorimeter data with irregular bins.
#include "calorimeters.C"
{
packH->SetElementName(
"Projections");
}
{
data->RefSliceInfo(0).Setup(
"ECAL", 0.3,
kRed);
data->RefSliceInfo(1).Setup(
"HCAL", 0.1,
kBlue);
}
data->AddTower(
ax->GetBinLowEdge(i),
ax->GetBinUpEdge(i),
ay->GetBinLowEdge(
j),
ay->GetBinUpEdge(
j));
data->FillSlice(1,
h2->GetBinContent(i,
j));
} else {
data->AddTower(
ax->GetBinLowEdge(i), 2 *
ax->GetBinWidth(i) +
ax->GetBinLowEdge(i),
ay->GetBinLowEdge(
j),
2 *
ay->GetBinWidth(
j) +
ay->GetBinLowEdge(
j));
data->FillSlice(0,
h2->GetBinContent(i,
j));
data->FillSlice(1,
h2->GetBinContent(i,
j));
}
}
}
}
ROOT::Detail::TRangeCast< T, true > TRangeDynCast
TRangeDynCast is an adapter class that allows the typed iteration through a TCollection.
R__EXTERN TEveManager * gEve
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void data
Visualization of a calorimeter event data in 2D.
Visualization of a calorimeter event data in 3D.
Calo data for universal cell geometry.
Visualization of calorimeter data as eta/phi histogram.
void AddElement(TEveElement *element, TEveElement *parent=nullptr)
Add an element.
TGLViewer * GetDefaultGLViewer() const
Get TGLViewer of the default TEveViewer.
TEveBrowser * GetBrowser() const
static TEveManager * Create(Bool_t map_window=kTRUE, Option_t *opt="FIV")
If global TEveManager* gEve is not set initialize it.
void FullRedraw3D(Bool_t resetCameras=kFALSE, Bool_t dropLogicals=kFALSE)
Perform 3D redraw of all scenes and viewers.
static TEveWindowSlot * CreateWindowInTab(TGTab *tab, TEveWindow *eve_parent=nullptr)
Create a new tab in a given tab-widget and populate it with a default window-slot.
static TFile * Open(const char *name, Option_t *option="", const char *ftitle="", Int_t compress=ROOT::RCompressionSetting::EDefaults::kUseCompiledDefault, Int_t netopt=0)
Create / open a file.
static Bool_t SetCacheFileDir(std::string_view cacheDir, Bool_t operateDisconnected=kTRUE, Bool_t forceCacheread=kFALSE)
Sets the directory where to locally stage/cache remote files.
void SetCurrentCamera(ECameraType camera)
Set current active camera - 'cameraType' one of: kCameraPerspX, kCameraPerspY, kCameraPerspZ,...
virtual Bool_t SetTab(Int_t tabIndex, Bool_t emit=kTRUE)
Brings the composite frame with the index tabIndex to the front and generate the following event if t...
virtual Int_t GetMaximumBin() const
Return location of bin with maximum value in the range.
virtual Double_t GetBinContent(Int_t bin) const
Return content of bin number bin.
2-D histogram with a float per channel (see TH1 documentation)
TGTab * GetTabRight() const
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.
Short_t Min(Short_t a, Short_t b)
Returns the smallest of a and b.