Created
August 1, 2020 15:20
-
-
Save vnegi10/15601832eb3de12fd6757a430898d978 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
confirmed_cases = vec(convert(Array, last(y,1))) # convert last dataframe row into a 1-D array | |
recovered_cases = vec(convert(Array, last(y_r,1))) | |
deaths = vec(convert(Array, last(y_d,1))) | |
Y = Array{Float64,2}(undef, length(names(y_r)), 4) # 2-D array with number of confirmed, recovered and deaths | |
Y[:,1] = deaths | |
Y[:,2] = confirmed_cases | |
Y[:,3] = recovered_cases | |
Y[:,4] = Y[:,2] - (Y[:,3] + Y[:,1]) # number of currently infected = confirmed - (recovered + deaths) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment