ROOT
git-r3/HEAD
Reference Guide
Loading...
Searching...
No Matches
read_from_file.C
Go to the documentation of this file.
1
void
read_from_file
(){
2
3
// Let's open the TFile
4
TFile
in_file(
"my_rootfile.root"
);
5
6
// Get the Histogram out
7
TH1F
*
h
;
8
in_file.
GetObject
(
"my_histogram"
,
h
);
9
10
// Draw it
11
auto
myCanvas =
new
TCanvas
();
12
h
->DrawClone();
13
}
h
#define h(i)
Definition
RSha256.hxx:106
TCanvas
The Canvas class.
Definition
TCanvas.h:23
TDirectory::GetObject
void GetObject(const char *namecycle, T *&ptr)
Get an object with proper type checking.
Definition
TDirectory.h:213
TFile
A file, usually with extension .root, that stores data and code in the form of serialized objects in ...
Definition
TFile.h:130
TH1F
1-D histogram with a float per channel (see TH1 documentation)
Definition
TH1.h:878
read_from_file
void read_from_file()
Definition
read_from_file.C:1
documentation
primer
macros
read_from_file.C
ROOTgit-r3/HEAD - Reference Guide Generated on
(GVA Time) using Doxygen 1.16.1