-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathplot_wait.m
47 lines (43 loc) · 1.05 KB
/
plot_wait.m
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
function [] = plot_wait(queue1Wait,queue2Wait,coronaTest)
% 7_2
numberOfPatients = length(coronaTest);
total_wait = queue1Wait + queue2Wait;
positive_patient_wait = [];
negative_patient_wait = [];
for i= 1:numberOfPatients
disp(i)
if coronaTest(i)== 1
disp('this')
positive_patient_wait = queue1Wait(i)+queue2Wait(i);
disp(positive_patient_wait)
disp('pos')
elseif coronaTest(i)== 0
disp('neg')
negative_patient_wait = queue1Wait(i)+queue2Wait(i);
end
end
plot(1:numberOfPatients,total_wait);
figure
hist(total_wait)
% hold;
% plot(negative_patient_wait,unique(positive_patient_wait));
% hold;
% plot(total_wait,unique(total_wait));
% hold;
% legend({'negative patients frequency ','positive patients frequency ', ...
% 'total patients frequency '})
% disp(total_wait)
% figure
% hist(total_wait);
%
% legend('total waitt time')
%
% figure
% hist(positive_patient_wait);
%
% legend('positive response time')
% figure
% hist(negative_patient_wait);
%
% legend('negative response time')
end