-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add un age dist #29
add un age dist #29
Conversation
epimodel/exports/epidemics_org.py
Outdated
d["Timezones"] = timezones["Timezone"].tolist() | ||
|
||
if un_age_dist is not None: | ||
d["AgeDist"] = un_age_dist.iloc[:-3].to_dict() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I am looking correctly at this, it means all columns but 95-99 | 100+
? So the population is not enough, you want to have it by age for future use on frontend for various purposes?
Also, please use explicit column names, pandas is clever and can do e.g. un_age_dist.loc[:"85-89"]
. Fighting bugs with number-indexed columns is crazy.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah that was just the quickest thing I could come up with, you probably know a better way: I just wanted to get rid of the columns "Type","Region Name","Parent Code M49".
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Btw. I think I could get the true population as we had it in the past under 30 minutes for all countries we export.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry I was unclear. What you wrote above was not my intent but rather I wanted to remove just the columns "Type","Region Name","Parent Code M49"
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes I think having the age distribution might be nice because we could use it in the future the calculate the CFR in some other way as those in rates.csv
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry I was unclear. What you wrote above was not my intent but rather I wanted to remove just the columns "Type","Region Name","Parent Code M49".
Then do un_age_dist.drop(columns=["Type","Region Name","Parent"])
to be explicit.
Yes I think having the age distribution might be nice because we could use it in the future the calculate the CFR in some other way as those in rates.csv.
OK, so keeping as is if you are fine with that?
Co-Authored-By: Daniel Hnyk <hnykda@users.noreply.github.com>
Can we merge this into #25 already? |
I fixed the |
No description provided.