Closed SM-ins closed 4 years ago
Dear Rakesh, Please use small characters as the arguments of methods like this.
ind_data = cs.CountryData("/kaggle/input/covid19-in-india/covid_19_india.csv",country="India")
Before: Country="India" After: country="India"
Thank you.
Dear Rakesh, Please read documentation of CountryData.set_variables() https://lisphilar.github.io/covid19-sir/covsirphy.cleaning.html#covsirphy.cleaning.country_data.CountryData.set_variables
(If you find errors or something to know, please let me know as always.)
Did you use the following dataset? https://www.kaggle.com/sudalairajkumar/covid19-in-india?select=covid_19_india.csv
I think the following codes will be necessary.
ind_data.set_variables(
date="Date", confirmed="Confirmed", fatal="Deaths", recovered="Cured", province="State/UnionTerritory"
)
Dear @lisphilar/covid19-sir reply@reply.github.com ,
Yes..,you are right..,the given code is necessary as column name were not matching..,thanks for the help..
With regards, Rakesh
On Sat, Jul 18, 2020 at 10:18 PM Lisphilar notifications@github.com wrote:
Dear Rakesh, Please read documentation of CountryData.set_variables()
(If you find errors or something to know, please let me know as always.)
Did you used the following dataset?
https://www.kaggle.com/sudalairajkumar/covid19-in-india?select=covid_19_india.csv
I think the following codes will be necessary.
ind_data.set_variables(date="Date", confirmed="Confirmed", fatal="Deaths", recovered="Cured", province="State/UnionTerritory" )
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/lisphilar/covid19-sir/issues/120#issuecomment-660509535, or unsubscribe https://github.com/notifications/unsubscribe-auth/AP6Y4PGNNOM25Y77WKYFPJDR4HG6BANCNFSM4O77E7SA .
Thank you! I will close this issue.
Dear Lisphilar,
i am agin encountering error in in running the above code:- ind_data = cs.CountryData("/kaggle/input/covid19-in-india/covid_19_india.csv",country="India") ind_data.set_variables( date="Date", confirmed="Confirmed", fatal="Deaths", recovered="Cured", province="State/UnionTerritory" ) ind_data.cleaned().tail()
ValueError: Cannot convert non-finite values (NA or inf) to integer Please look into it....
With regards, Rakesh
Dear Rakesh,
It seems that NA values were added to the raw dataset.
I will add .fillna(0)
in cleaning method ofcs.CountryData
class.
Dear Lisphilar, Thanks for the response...,okey..kindly let me know after adding it..
Dear Rakesh, I fixed this in version 2.6.0-alpha.fix.120 Please confirm it.
Dear @lisphilar ,
while running the following code,i am getting mentioned error:-
ind_data = cs.CountryData("/kaggle/input/covid19-in-india/covid_19_india.csv",Country="India") ind_data.set_variables( date="Date", confirmed="Positive", fatal="Fatal", recovered="Discharged", province=None ) ind_data.cleaned().tail()
TypeError: init() got an unexpected keyword argument 'Country'
I just replace the country by India in place of japan and change the file path too...,but in spite of that I am getting above error..,will you please help..
With regards, Rakesh