Description Usage Arguments Value Examples
View source: R/deterministicmodel_inadjusted_trafficregulated_quarantine.R
This function gives deterministic realization for n countries with a given regulated strategy and quarantine duration that each country required.
1 | deterministicmodel_inadjusted_trafficregulated_quarantine(thetamatrix, inp)
|
thetamatrix |
is a matrix of parameters, parameters of each country is on 1 row |
inp |
is a list include durationtravel : durationtravel (days), durationquarantine_adjustedin : number of days people travel in have to quarantine based on each country policy, travelregulated: a list of travel allowed from 1 country to another during the duration, initialmatrix is a matrix of initial compartments of countries, each country is on 1 row, and quarantinerate is the rate people follow quarantine |
The average realization of n countries with travel data regulated
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 | ## Not run:
library(CONETTravel)
P1 = 10^7
I1 = 250
A1 = 130
S1 = P1 - I1 - A1
x1 = c(S1,I1,A1,0,0,0) # State corresponding S,I,A,R,D,Ru country 1
P2 = 3*10^6
I2 = 20
A2 = 10
S2 = P2 - I2 - A2
x2 = c(S2,I2,A2,0,0,0) # State corresponding S,I,A,R,D,Ru country 2
P3 = 2*10^6
I3 = 15
A3 = 15
S3 = P3 - I3 - A3
x3 = c(S3,I3,A3,0,0,0) # State corresponding S,I,A,R,D,Ru country 3
travelout_data = travelout_3dat
initial_corona = as.matrix(rbind(x1,x2,x3) )#initial conditions of 3 countries
P = c(P1, P2, P3) #population 3 countries
k = 13
theta0 = rbind(thetas_3travel[[k]][1:6],thetas_3travel[[k]][7:12],thetas_3travel[[k]][13:18])
ratein = 1 # policy that allows full rate of travel in
traveloutDivideRegulated = totaltravelout_samerate_regulated(travelout_data, ratein, P)
inp = list(durationtravel = nrow(travelout_data), travelregulated = traveloutDivideRegulated,
initialmatrix = initial_corona, quarantinerate = 1, durationquarantine_adjustedin = c(14,14,14))
deterministicmodel_inadjusted_trafficregulated_quarantine(theta0, inp)
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.