void ana_hc_task(TString InFile="test_fast.root", int nevts=0, double pbarmom=5.61190138, TString Method="PHSP") { // *** the output file for FairRunAna TString OutFile = InFile+"_"; OutFile += Method; OutFile += "_taskana.root"; TString OutFileDummy = InFile+"_"; OutFileDummy += Method; OutFileDummy += "_taskana_dummy.root"; // *** initialization FairLogger::GetLogger()->SetLogToFile(kFALSE); FairRunAna* fRun = new FairRunAna(); fRun->SetWriteRunInfoFile(kFALSE); fRun->SetInputFile(InFile); fRun->SetOutputFile(OutFileDummy); // *** take constant field; needed for PocaVtx RhoCalculationTools::ForceConstantBz(20.0); // *** HERE OUR ANALYSIS TASK GOES! PndScrutAnaTask *scrutTask = new PndScrutAnaTask(pbarmom, OutFile); scrutTask->SetMethod(Method);//Set assumptions used in analysis: OmegaEta (overwise no assumption was used) fRun->AddTask(scrutTask); // *** and run analysis fRun->Init(); fRun->Run(0,nevts); }