``` {r libraries, include = FALSE} library(tibble) library(tidyr) library(readr) library(purrr) library(dplyr) library(stringr) library(forcats) library(tidyr) library(readxl) library(lubridate)
``` {r variables, echo = FALSE, include = FALSE} setwd("../data") path <- params$source_filename sheet_names <- readxl::excel_sheets(path = path) variables <- map(.x = sheet_names, .f = function(x) { readxl::read_xlsx(path = path, sheet = x) }) %>% purrr::set_names(sheet_names) variables$Experience <- variables$Experience %>% arrange(desc(To)) full_name <- variables$Contact %>% filter(Field == "Full Name") %>% pull(Value) email <- variables$Contact %>% filter(Field == "Email") %>% pull(Value) phone <- variables$Contact %>% filter(Field == "Phone Number") %>% pull(Value) github_name <- variables$Contact %>% filter(Field == "Github") %>% pull(Value) github_link <- paste("https:://", github_name) linkedin_name <- variables$Contact %>% filter(Field == "LinkedIn") %>% pull(Value) linkedin_link <- paste("https:://", linkedin_name) blurb <- variables$Additional %>% filter(Field == "Overview") %>% pull(Value) skills_descriptors <- if (nrow(variables$Skills > 0)) { pmap( .l = list( x = variables$Skills$Skill, y = variables$Skills$Description ), .f = function(x, y) { paste0("- **", x, "** - ", y, "\n\n") } ) %>% unlist() %>% paste(collapse = "") } else { NA } skills_noDescriptors <- if (nrow(variables$Skills > 0)) { pmap( .l = list( x = variables$Skills$Skill ), .f = function(x, y) { paste0("- **", x, "**\n\n") } ) %>% unlist() %>% paste(collapse = "") } else { NA } education <- pmap(.l = list(name = variables$Education$Name, degree = variables$Education$Degree, minor = variables$Education$Minor, where = variables$Education$Where, grad = variables$Education$`Graduation Date`), .f = function(name, degree, minor, where, grad) { paste( paste0("### ", name), degree, where, paste0("Grad Date:", ymd(grad) %>% format.Date(format = "%b '%y")), if(!is.na(minor)){paste0("Minored in ", minor)}, sep = "\n\n" ) }) %>% unlist() %>% paste0(collapse = "") professional <- pmap(.l = list(title = variables$Experience$Title, company = variables$Experience$Company, where = variables$Experience$Where, from = variables$Experience$From, to = variables$Experience$To, bp1 = variables$Experience$`Bullet Point 1`, bp2 = variables$Experience$`Bullet Point 2`, bp3 = variables$Experience$`Bullet Point 3`, bp4 = variables$Experience$`Bullet Point 4`, bp5 = variables$Experience$`Bullet Point 5`, bp6 = variables$Experience$`Bullet Point 6`), .f = function(title, company, where, from, to, bp1, bp2, bp3, bp4, bp5, bp6){ paste( paste0("### ", title), company, where, paste( year(from), year(to), sep = " - "), paste0( "::: consice\n", paste0("- ", bp1, "\n"), if(!is.na(bp2)){paste0("- ", bp2, "\n")}, if(!is.na(bp3)){paste0("- ", bp3, "\n")}, if(!is.na(bp4)){paste0("- ", bp4, "\n")}, if(!is.na(bp5)){paste0("- ", bp5, "\n")}, if(!is.na(bp6)){paste0("- ", bp6, "\n")}, ":::\n\n"), sep = "\n\n") }) %>% unlist() %>% paste(collapse = "")
r email
r github_name
r linkedin_name
r phone
r if(params$skill_descriptors == TRUE){skills_descriptors}else{skills_noDescriptors}
r full_name
{#title}r blurb
r education
r professional
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.