-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathexpt.cpp
61 lines (54 loc) · 2.26 KB
/
expt.cpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
#include <random>
#include "all.cpp"
std::vector<int> Ns = {100, 1000, 10000, 100000, 1000000};
int R = 100;
int main() {
std::mt19937 mt(1234);
NE::TestCase m1;
NE::NMC e11(m1);
NE::Proposed e12(m1);
NE::ProposedWithRegression e13(m1);
NE::Strong e14(m1, "/dev/shm");
printf("Estimating Nested Expectation with NMC for TestCase...\n");
visualize(Ns, R, e11, "output/ne_testcase_nmc.txt", mt);
printf(
"Estimating Nested Expectation with Proposed Method for TestCase...\n");
visualize(Ns, R, e12, "output/ne_testcase_proposed.txt", mt);
printf(
"Estimating Nested Expectation with Proposed Method with regression "
"for TestCase...\n");
visualize(Ns, R, e13, "output/ne_testcase_proposed_reg.txt", mt);
printf(
"Estimating Nested Expectation with Strong et al. for TestCase...\n");
visualize(Ns, R, e14, "output/ne_testcase_strong.txt", mt);
EVSI::TestCase m2(3);
EVSI::NMC e21(m2);
EVSI::Proposed e22(m2);
EVSI::ProposedWithRegression e23(m2);
EVSI::Strong e24(m2, "/dev/shm");
printf("Estimating EVSI with NMC for TestCase...\n");
visualize(Ns, R, e21, "output/evsi_testcase_nmc.txt", mt);
printf("Estimating EVSI with Proposed Method for TestCase...\n");
visualize(Ns, R, e22, "output/evsi_testcase_proposed.txt", mt);
printf(
"Estimating EVSI with Proposed Method with regression for "
"TestCase...\n");
visualize(Ns, R, e23, "output/evsi_testcase_proposed_reg.txt", mt);
printf("Estimating EVSI with Strong et al. for TestCase...\n");
visualize(Ns, R, e24, "output/evsi_testcase_strong.txt", mt);
EVSI::Medical m3;
EVSI::Proposed e32(m3);
EVSI::ProposedWithRegression e33(m3);
EVSI::Strong e34(m3, "/dev/shm");
printf(
"Estimating EVSI with Proposed Method for Medical Decision Model...\n");
visualize(Ns, R, e32, "output/evsi_medical_proposed.txt", mt);
printf(
"Estimating EVSI with Proposed Method with regression for Medical "
"Decision Model...\n");
visualize(Ns, R, e33, "output/evsi_medical_proposed_reg.txt", mt);
printf(
"Estimating EVSI with Strong et al. for Medical Decision Model...\n");
visualize(Ns, R, e34, "output/evsi_medical_strong.txt", mt);
return 0;
}