library(Hmisc)
library(janitor)
library(naniar)
library(xfun) ## or, if you prefer use library(sessioninfo)
# if you wish to add other packages, do so here
library(tidyverse)
::opts_chunk$set(comment = NA) knitr
431 Project A Portfolio Report Template
You will get more out of this template if you work with it in combination with the 431 Project A Sample Portfolio Report, which provides more detail for each section of the Portfolio.
See the Project A Examples for more details and useful links.
Be certain to delete this note when you submit your final portfolio, along with my other instructions.
1 R Packages
Follow the instructions for this section found in the R Packages section of the Proposal page.
Leave in the code below, augmenting it with additional packages as necessary, where indicated.
2 Data Ingest
Follow the instructions for this section found in Data Task 1 on the Data page, as well as the Data Ingest section of the Proposal page.
A little bit of important code is included below.
<-
data_url "https://www.countyhealthrankings.org/sites/default/files/media/document/analytic_data2023_0.csv"
<- read_csv(data_url, skip = 1, guess_max = 4000,
chr_2023_raw show_col_types = FALSE)
3 State Selection
Follow the instructions for this section found in Data Task 2 on the Data page, as well as the State Selection section of the Proposal page.
4 Variable Selection
Follow the instructions for this section found in Data Task 3 on the Data page, as well as the Variable Selection section of the Proposal page.
5 Variable Cleaning and Renaming
Follow the instructions for this section found at the end of Data Task 3 on the Data page, as well as the Variable Cleaning and Renaming section of the Proposal page. .
6 Creating the Analysis 2 Predictor
Follow the instructions for this section found in Data Task 4 on the Data page, as well as the Creating the Analysis 2 Predictor section of the Proposal page. .
7 Adding 2018 Data for the Analysis 3 Outcome
Follow the instructions for this section found in Data Task 5 on the Data page, as well as the Adding 2018 Data for the Analysis 3 Outcome section of the Proposal page.
8 Arranging and Saving the Analytic Tibble
Follow the instructions for this section found in Data Task 6 on the Data page, as well as the Arranging and Saving the Analytic Tibble section of the Proposal page.
9 Print the Tibble
Follow the relevant instructions for this section found on the Proposal page.
10 Numerical Summaries
Follow the relevant instructions for this section found on the Proposal page.
11 The Codebook
Follow the relevant instructions for this section found on the Proposal page.
Our add name of tibble tibble contains add code counties and add code variables.
Variable | Original | Role | NA | Distinct | Definition |
---|---|---|---|---|---|
fipscode | – | ID | add code | add code | county’s FIPS code |
state | – | ID | add code | add code | state postal abbreviation |
county | – | ID | add code | add code | county name |
add other selected variables | - | - | - | - | - |
county_ranked | – | Check | add code | add code | be sure that all values are 1 |
Missingness Check goes here.
Distinct Values Check goes here.
12 Research Questions
Follow the relevant instructions for this section, and its subsections, found on the Proposal page.
12.1 Analysis 1 Research Question
12.2 Analysis 2 Research Question
12.3 Analysis 3 Research Question
13 Analysis 1
Follow the instructions on the Analyses page carefully.
13.1 Variables
13.2 Summaries
13.3 Approach
13.4 Conclusions
14 Analysis 2
Follow the instructions on the Analyses page carefully.
14.1 Variables
14.2 Summaries
14.3 Approach
14.4 Conclusions
15 Analysis 3
Follow the instructions on the Analyses page carefully.
15.1 Variables
15.2 Summaries
15.3 Approach
15.4 Conclusions
16 Portfolio Reflections
The original “Proposal Reflections” section is only included as Section 13 in the Proposal, and should not be included in the final portfolio report. Instead, write a new paragraph (containing at least four well-constructed complete English sentences) to answer the following question:
What was the most important thing you learned as a result of doing this project, and why?
17 Session Information
session_info()
R version 4.3.1 (2023-06-16 ucrt)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 11 x64 (build 22621)
Locale:
LC_COLLATE=English_United States.utf8
LC_CTYPE=English_United States.utf8
LC_MONETARY=English_United States.utf8
LC_NUMERIC=C
LC_TIME=English_United States.utf8
time zone: America/New_York
tzcode source: internal
Package version:
askpass_1.2.0 backports_1.4.1 base64enc_0.1-3
bit_4.0.5 bit64_4.0.5 blob_1.2.4
broom_1.0.5 bslib_0.5.1 cachem_1.0.8
callr_3.7.3 cellranger_1.1.0 checkmate_2.2.0
cli_3.6.1 clipr_0.8.0 cluster_2.1.4
colorspace_2.1-0 compiler_4.3.1 conflicted_1.2.0
cpp11_0.4.6 crayon_1.5.2 curl_5.1.0
data.table_1.14.8 DBI_1.1.3 dbplyr_2.3.4
digest_0.6.33 dplyr_1.1.3 dtplyr_1.3.1
ellipsis_0.3.2 evaluate_0.22 fansi_1.0.4
farver_2.1.1 fastmap_1.1.1 fontawesome_0.5.2
forcats_1.0.0 foreign_0.8-84 Formula_1.2-5
fs_1.6.3 gargle_1.5.2 generics_0.1.3
ggplot2_3.4.3 glue_1.6.2 googledrive_2.1.1
googlesheets4_1.1.1 graphics_4.3.1 grDevices_4.3.1
grid_4.3.1 gridExtra_2.3 gtable_0.3.4
haven_2.5.3 highr_0.10 Hmisc_5.1-1
hms_1.1.3 htmlTable_2.4.1 htmltools_0.5.6
htmlwidgets_1.6.2 httr_1.4.7 ids_1.0.1
isoband_0.2.7 janitor_2.2.0 jquerylib_0.1.4
jsonlite_1.8.7 knitr_1.44 labeling_0.4.3
lattice_0.21.8 lifecycle_1.0.3 lubridate_1.9.3
magrittr_2.0.3 MASS_7.3.60 Matrix_1.6.1.1
memoise_2.0.1 methods_4.3.1 mgcv_1.8.42
mime_0.12 modelr_0.1.11 munsell_0.5.0
naniar_1.0.0 nlme_3.1.162 nnet_7.3-19
norm_1.0.11.1 openssl_2.1.1 parallel_4.3.1
pillar_1.9.0 pkgconfig_2.0.3 plyr_1.8.9
prettyunits_1.2.0 processx_3.8.2 progress_1.2.2
ps_1.7.5 purrr_1.0.2 R6_2.5.1
ragg_1.2.5 rappdirs_0.3.3 RColorBrewer_1.1.3
Rcpp_1.0.11 readr_2.1.4 readxl_1.4.3
rematch_2.0.0 rematch2_2.1.2 reprex_2.0.2
rlang_1.1.1 rmarkdown_2.25 rpart_4.1.19
rstudioapi_0.15.0 rvest_1.0.3 sass_0.4.7
scales_1.2.1 selectr_0.4.2 snakecase_0.11.1
splines_4.3.1 stats_4.3.1 stringi_1.7.12
stringr_1.5.0 sys_3.4.2 systemfonts_1.0.4
textshaping_0.3.6 tibble_3.2.1 tidyr_1.3.0
tidyselect_1.2.0 tidyverse_2.0.0 timechange_0.2.0
tinytex_0.47 tools_4.3.1 tzdb_0.4.0
UpSetR_1.4.0 utf8_1.2.3 utils_4.3.1
uuid_1.1.1 vctrs_0.6.3 viridis_0.6.4
viridisLite_0.4.2 visdat_0.6.0 vroom_1.6.4
withr_2.5.1 xfun_0.40 xml2_1.3.5
yaml_2.3.7