Multiple runs and storing in .root

Solved the issue. I can output multiple .root files (1 for each run) using,
analysisManager->Clear();
analysisManager->Reset();
in BeginRunAction.

Edit.
When the multiple root files were generated, I used the command
hadd -f Results.root output*.root*
This command combine all the root files i generated i.e. output0.root output1.root output2.root …