]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PWGLF/FORWARD/analysis2/MakeFlow.C
Merge branch 'feature-movesplit'
[u/mrichter/AliRoot.git] / PWGLF / FORWARD / analysis2 / MakeFlow.C
1 /**
2  * @file   MakeFlow.C
3  * @author Alexander Hansen 
4  * 
5  * @brief  
6  * 
7  * @ingroup pwglf_forward_scripts_makers
8  * 
9  */
10 //====================================================================
11 /**
12  * Script to analyse AOD input for flow
13  * 
14  * @param name     Name of train 
15  * @param options  Options @see RunTrain 
16  * @param mode     Which execution environment 
17  * @param datadir  Data directory/proof path 
18  * @param urlOpts  URL options
19  *
20  * @ingroup pwglf_forward_flow
21  */
22 void MakeFlow(TString name    = "flow", 
23               TString options = "help",
24               TString mode    = "lite",
25               TString datadir = "",
26               TString urlOpts = "workers=10&recursive") 
27 {
28   if (name.IsNull()) Fatal("MakeFlow", "Must specify a name");
29   gROOT->SetMacroPath(Form("%s:$ALICE_ROOT/PWGLF/FORWARD/analysis2/trains",
30                            gROOT->GetMacroPath()));
31   
32   gROOT->LoadMacro("$ALICE_ROOT/PWGLF/FORWARD/trains/RunTrain.C");
33
34   if (!datadir.EndsWith("/") && !mode.Contains("proof")) datadir.Append("/");
35   
36   TUrl url(datadir.Data());
37   url.SetProtocol(mode.Data());
38   url.SetAnchor("aodTree");
39   url.SetOptions(urlOpts.Data());
40
41   RunTrain(name, "MakeFlowTrain", url, options);
42 }
43 //--------------------------------------------------------------------
44 //
45 // EOF
46 //