When I use the TFileMerger class for files that contains TNtuples, I get two identical copies of each Ntuple in the merged file. Is there a reason for this? A way to avoid it?
I am using root 5.18 and here is the main part of the macro I use to merge the files:
TFileMerger m;
if (outfile) m.OutputFile(outfile);
Int_t i=0;
TString fName = 0x0;
while (result->GetKey(i,“turl”)) {
fName = result->GetKey(i,“turl”);
fName += file;
m.AddFile(fName);
i++;
}
if (i) m.Merge();
Could you post the real RUNNING script that you use for the merge and also the data files.
In case the data file(s) is big, put them somewhere in a public area (eg AFS).
Also note that we provide a utility to merge ROOT files automatically in $ROOTSYS/bin/hadd