Jiranuwat commited on
Commit
e40487e
·
1 Parent(s): 4142885

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -1
app.py CHANGED
@@ -147,10 +147,15 @@ def main():
147
  # Show SIR
148
  SIR_param = SIR(country_code,R0,recovery,pop)
149
 
 
 
 
 
 
150
  st.pyplot(SIR_param[-2])
151
  st.pyplot(SIR_param[-1])
152
  st.success("SIR model parameters of Thailand "+" is")
153
- st.success("R0 (Basic Reproduction Number) = "+str(SIR_param[0]))
154
  st.success("Beta (Rate of transmission) = "+str(round(SIR_param[2],3)))
155
  st.success("Gamma (Rate of Recovery) = "+str(round(SIR_param[3],3)))
156
  st.success("MAPE = "+str(round(SIR_param[4],3))+"%")
 
147
  # Show SIR
148
  SIR_param = SIR(country_code,R0,recovery,pop)
149
 
150
+ if SIR_param[0] <= 1:
151
+ a = 'No epidemic.'
152
+ else:
153
+ a = 'Epidemic has began.'
154
+
155
  st.pyplot(SIR_param[-2])
156
  st.pyplot(SIR_param[-1])
157
  st.success("SIR model parameters of Thailand "+" is")
158
+ st.success("R0 (Basic Reproduction Number) = "+str(SIR_param[0])+' '+a)
159
  st.success("Beta (Rate of transmission) = "+str(round(SIR_param[2],3)))
160
  st.success("Gamma (Rate of Recovery) = "+str(round(SIR_param[3],3)))
161
  st.success("MAPE = "+str(round(SIR_param[4],3))+"%")