Are there associations between new HIV incident infections and state GDP 2008-2020
This is homework number three. As a results of highly effective, tolerable antiretroviral therapy and effective prevention strategies, there has been a decrease in incident HIV infections and deaths over the years. Unfortunately, some states are still experiencing more incident infections than others. There are two data sets that this project will look at. The first is state level HIV incidence data and the second is state level health care GDP.
The first data set looks at state level annual HIV incident infections1. The variables in this data set:
str(HIV.State)
tibble [714 × 4] (S3: tbl_df/tbl/data.frame)
$ Year : num [1:714] 2021 2020 2019 2018 2017 ...
$ Geography : chr [1:714] "Alabama" "Alabama" "Alabama" "Alabama" ...
$ Cases : num [1:714] 314 586 638 607 650 653 663 664 630 663 ...
$ Rate per 100000: chr [1:714] "Data not available" "Data not available" "15.5" "14.8" ...
head(HIV.State)
# A tibble: 6 × 4
Year Geography Cases `Rate per 100000`
<dbl> <chr> <dbl> <chr>
1 2021 Alabama 314 Data not available
2 2020 Alabama 586 Data not available
3 2019 Alabama 638 15.5
4 2018 Alabama 607 14.8
5 2017 Alabama 650 15.9
6 2016 Alabama 653 16.0
This second dataset looks at annual state level GDP2.
The variables in this data set:
# This is dataset #2
# This data was obatined from https://apps.bea.gov/itable/iTable.cfm?ReqID=70&step=1
GDP.State <- read_csv("StateGDP.csv", skip = 4)
GDP.State <- GDP.State %>%
select(2,4:17)
GDP.State <- GDP.State %>%
pivot_longer(
`2008`: `2020`,
names_to = "Year",
values_to = "GDP"
)
str(GDP.State)
tibble [2,405 × 4] (S3: tbl_df/tbl/data.frame)
$ GeoName : chr [1:2405] "United States *" "United States *" "United States *" "United States *" ...
$ Description: chr [1:2405] "Health care and social assistance" "Health care and social assistance" "Health care and social assistance" "Health care and social assistance" ...
$ Year : chr [1:2405] "2008" "2009" "2010" "2011" ...
$ GDP : num [1:2405] 1017197 1078771 1112327 1149944 1195074 ...
head(GDP.State)
# A tibble: 6 × 4
GeoName Description Year GDP
<chr> <chr> <chr> <dbl>
1 United States * Health care and social assistance 2008 1017197
2 United States * Health care and social assistance 2009 1078771
3 United States * Health care and social assistance 2010 1112327
4 United States * Health care and social assistance 2011 1149944
5 United States * Health care and social assistance 2012 1195074
6 United States * Health care and social assistance 2013 1230767
Text and figures are licensed under Creative Commons Attribution CC BY-NC 4.0. The figures that have been reused from other sources don't fall under this license and can be recognized by a note in their caption: "Figure from ...".
For attribution, please cite this work as
Nguyen (2022, April 3). Data Analytics and Computational Social Science: HNguyen HW 3. Retrieved from https://github.com/DACSS/dacss_course_website/posts/httpsrpubscomhenryfnp885437/
BibTeX citation
@misc{nguyen2022hnguyen, author = {Nguyen, Henry}, title = {Data Analytics and Computational Social Science: HNguyen HW 3}, url = {https://github.com/DACSS/dacss_course_website/posts/httpsrpubscomhenryfnp885437/}, year = {2022} }