I run the macro below using root macro.C+ and then do gDirectory->ls() and I don’t see intree in the output of gDirectory->ls(). Why? When I uncomment the last line and comment the second to last line, then I do see intree in the gDirectory->ls() output. Can someone explain this?
TFile * weight_file = new TFile(“file.root”);
TChain *chain = new TChain(“tree_name”);
TTree *intree = chain;
//TTree *intree = new TTree(“tree_name”,“tree_name”);