Dear Rooters
I have a root file(xyz.root) with Tree name ‘t’ and leaf name ‘vertex_m’. I need to rename them . I am able to rename Tree but failed for leaf(branch).
how to rename the branch ? I am looking for support.
Kalakhety
Dear Rooters
I have a root file(xyz.root) with Tree name ‘t’ and leaf name ‘vertex_m’. I need to rename them . I am able to rename Tree but failed for leaf(branch).
how to rename the branch ? I am looking for support.
Kalakhety
see Rename Branch
Hi
I have seen this page and use it, but it failed to rename branch.
--------my macro is:---------
TFile *oldfile = new TFile(“himali_dimuon_data_4076invpb.root”);
TTree oldtree = (TTree)oldfile->Get(“t”);
TFile *newfile = new TFile(“himali_dimuon_data_4076invpb_Aug292012.root”,“recreate”);
TTree *newtree = oldtree->CloneTree();
It rename the tree but not branch. is there any thing missing?
Kalakhety