Data Study on Zika Virus Infections
The skills the author demoed here can be learned through taking Data Science with Machine Learning bootcamp with NYC Data Science Academy.
About the Zika Virus
The Zika virus is a mosquito-borne virus carried by the Aedes type of mosquitoes. Data shows the virus was first isolated in 1947 from the Zika Forest of Uganda, where it inherits it's name. The infection is very similar to the dengue fever, having symptoms such as fever, rash, joint pain, as well as conjunctivitis. Contracting the the infection during pregnancy has the potential to cause a birth defect of the brain called microcephaly and other severe fetal brain defects.
Data Acquisition and Cleansing
The data used in this visualization project comes from two main sources:
- A data set from Kaggle website on Zika infections provided by the CDC - https://www.kaggle.com/cdc/zika-virus-epidemic
- Shape files for mapping the data to administrative areas found was found on - www.gadm.org
The data set for the Zika virus information includes the following fields:
- report_date - The report date is the date that the report was published. The date should be specified in standard ISO format (YYYY-MM-DD).
- location - A location is specified for each observation following the specific names specified in the country place name database. This may be any place with a 'location_type' as listed below, e.g. city, state, country, etc. It should be specified at up to three hierarchical levels in the following format: [country]-[state/province]-[county/municipality/city], always beginning with the country name. If the data is for a particular city, e.g. Salvador, it should be specified: Brazil-Bahia-Salvador.
- A location code is included indicating: city, district, municipality, county, state, province, or country. If there is need for an additional 'location_type', open an Issue to create a new 'location_type'.
- data_field - The data field is a short description of what data is represented in the row and is related to a specific definition defined by the report from which it comes.
- data_field_code - This code is defined in the country data guide. It includes a two letter country code (ISO-3166 alpha-2, list), followed by a 4-digit number corresponding to a specific report type and data type.
- time_period - Optional. If the data pertains to a specific period of time, for example an epidemiological week, that number should be indicated here and the type of time period in the 'time_period_type', otherwise it should be NA.
- time_period_type - Required only if 'time_period' is specified. Types will also be specified in the country data guide. Otherwise should be NA.
- value - The observation indicated for the specific 'report_date', 'location', 'data_field' and when appropriate, 'time_period'.
- The unit of measurement for the 'data_field'. This should conform to the 'data_field' unit options as described in the country-specific data guide.
Once the data was pulled into R, it was necessary to clean the dates, breakout data into probable and confirmed cases, as well as separate the location field into administrative districts so that it could be merged with the locations in pulled from www.gadm.org shape files by country.
Below is the code used for this process:
After merging the data to the shape files, I was then able to create a small app to visualize the Zika virus data set by country and by confirmed or probable cases.