runProtoDUNEFit.cc
Go to the documentation of this file.
1 #include <iostream>
2 #include <fstream>
3 #include <sstream>
4 #include <string>
5 
10 
11 #include "ProtoDUNEFit.h"
12 
13 #include "TFile.h"
14 
15 int main(int argc, char ** argv){
16 
17  std::string fhcfile;
18  TString Outputfile;
19  int analysis = -1;
20  // Options to run
21  for(int iArg = 1; iArg < argc; iArg++){
22  if((!strcasecmp(argv[iArg],"-f")) || (!strcasecmp(argv[iArg],"-fhc"))) {
23  fhcfile = argv[++iArg];
24  }
25  if((!strcasecmp(argv[iArg],"-o")) || (!strcasecmp(argv[iArg],"-output"))) {
26  Outputfile = TString(argv[++iArg]);
27  }
28  if((!strcasecmp(argv[iArg],"-h")) || (!strcasecmp(argv[iArg],"-help"))) {
29  std::cout << "Usage: runProtoDUNEFit -f fclfile.fcl -o outputfile.root [-pions]" << std::endl;
30  return 1;
31  }
32  if((!strcasecmp(argv[iArg],"-pions")) || (!strcasecmp(argv[iArg],"--pions"))) {
33  analysis = 1;
34  }
35  }
36 
38  pfit->BuildWorkspace(Outputfile, analysis);
39 
40  return 0;
41 }
std::string string
Definition: nybbler.cc:12
int main(int argc, char **argv)
void BuildWorkspace(TString Outputfile, int analysis=-1)
QTextStream & endl(QTextStream &s)