ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/cbrown/AnalysisFramework/DistributedModelCalculations/Limits/LimitCapsule.C
Revision: 1.4
Committed: Tue Nov 8 15:57:29 2011 UTC (13 years, 6 months ago) by buchmann
Content type: text/plain
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +0 -0 lines
State: FILE REMOVED
Error occurred while calculating annotation data.
Log Message:
Removed all limits/efficiency plotting scripts as they have been supersededby PlotScanResults.C

File Contents

# Content
1 #include <iostream>
2 #include <vector>
3 #include <sys/stat.h>
4 #include "../../Plotting/Modules/LimitDroplet.C"
5 #include "../../Plotting/Modules/GeneralToolBox.C"
6 #include "../../Plotting/Modules/SampleClass.C"
7 #include "../../Plotting/Modules/Setup.C"
8 //#include "../../Plotting/Modules/external/cl95cms.c"
9
10
11 /*
12
13 This capsule computes the limits; the advantage is that in this way the capsule can fail (segfault/...) without problems, while the main program is not affected.
14
15 */
16
17 int main(int nargs, char* args[]) {
18 /* we obtain lumi etc. directly from the template; the only things passed are the following:
19 - report filename [1]
20 - luminosity [2]
21 - lumi uncert [3]
22 - MC efficiency [4]
23 - MC efficiency error [5]
24 - Npred [6]
25 - Nprederr [7]
26 - Nobs [8]
27 - JZB cut [9]
28 - plot name [10]
29 */
30
31 if(nargs<11) {
32 cout << "NOT ENOUGH ARGUMENTS!" << endl;
33 return -1;
34 }
35
36 string reportname=args[1];
37 float luminosity=atof(args[2]);
38 float lumiuncert=atof(args[3]);
39 float mceff=atof(args[4]);
40 float mcefferr=atof(args[5]);
41 float Npred=atof(args[6]);
42 float Nprederr=atof(args[7]);
43 float Nobs=atof(args[8]);
44 int JZBcutused=atoi(args[9]);
45 string plotname=args[10];
46
47 std::cout << "Now calling : CL95(" << luminosity << "," << lumiuncert << "," << mceff << "," << mcefferr << "," << Npred << "," << Nprederr << "," << Nobs << "," << false << "," << PlottingSetup::nuisancemodel<< ") " << std::endl;
48
49 float sigma95 = 0;
50 //CL95(luminosity, lumiuncert, mceff, mcefferr, Npred, Nprederr, Nobs, false, PlottingSetup::nuisancemodel);
51 write_error(__FUNCTION__,"LimitCapsule is outdated - use NewLimitCapsule (based on roostats)");
52 LimitDroplet limres;
53 limres.JZB=JZBcutused;
54 limres.upper68=-2;
55 limres.lower68=-3;
56 limres.expected=-4;
57 limres.observed=sigma95;
58 limres.upper95=-6;
59 limres.lower95=-7;
60 //needs to be updated once we switch to roostats :-) at that point we'll have all this information.
61 limres.saveDroplet(reportname);
62
63 return 0;
64 }