Functions to build complex elements from CV data.

build_title(
  name = "Leonardo da Vinci",
  logo = get_logo(),
  tagline = "Curriculum Vitae",
  extra = list("### My Affiliation", "### My Current Job", "### My Degrees"),
  logo_position = c("right", "left", "bottom")
)

build_toc(items = NULL, div = "h4", collapse = "<br>")

build_footer(
  add_github = "https://github.com/bschilder/autoCV",
  add_pagedown = FALSE,
  add_date = TRUE,
  img_width = "15px",
  sep = "<br>"
)

build_summary(
  wd = "./",
  files = get_data(dir_manual = wd, subdir = "cv_data"),
  items = c("n_years_experience_research", "n_publications", "n_preprints", "n_packages",
    "n_databases", "n_talks", "n_years_experience_teaching"),
  plus = list(n_years_experience_research = "+", n_publications = "", n_preprints = "",
    n_packages = "", n_databases = "", n_talks = "", n_years_experience_teaching = "+"),
  collapse = "<br>"
)

build_network(
  files = list.files(path = file.path("cv_data"), pattern = ".csv$", full.names = TRUE),
  min_count = 2,
  min_nchar = 2,
  layout = "layout_as_star",
  center = tolower("BM Schilder"),
  shape = "hexagon",
  randomSeed = 2023,
  save_path = NULL,
  show_plot = TRUE,
  height = 700,
  width = 1200,
  export_type = "png"
)

build_skill_bars(percent, title = "")

build_skills_plot(
  wd = "./",
  file = file.path(wd, "cv_data", "skills.csv"),
  types = NULL,
  label_alpha = 0.8,
  fill_alpha = 0.8,
  polar = FALSE,
  show_plot = TRUE,
  save_path = NULL,
  ...
)

Arguments

name

Your name to put on the CV.

logo

Logo to use.

tagline

Tagline to use.

extra

Extra HTML/markdown elements to append.

logo_position

Position of the logo relative to the title.

items

A subset of items to get from the autoCV::icon_dict.

div

HTML div class.

collapse

an optional character string to separate the results. Not NA_character_.

add_github

Add link to autoCV GitHub repo.

add_pagedown

Add pagedown reference.

add_date

Add date CV last updated.

img_width

Image width.

sep

a character string to separate the terms. Not NA_character_.

wd

Working directory where the "cv_data" and "img" subfolders are stored.

files

Named list containing paths to CV data files.

plus

Extra symbols (e.g. "+") to include at the end of each respective element.

min_count

Minimum word count.

min_nchar

Minimum word length.

layout

: Character Name of igraph layout function to use. Default to "layout_nicely"

center

Center node ID.

shape

: String. Default to 'ellipse'. The shape defines what the node looks like. There are two types of nodes. One type has the label inside of it and the other type has the label underneath it. The types with the label inside of it are: ellipse, circle, database, box, text. The ones with the label outside of it are: image, circularImage, diamond, dot, star, triangle, triangleDown, hexagon, square and icon.

randomSeed

: Number. The nodes are randomly positioned initially. This means that the settled result is different every time. If you provide a random seed manually, the layout will be the same every time.

save_path

Path to save to.

show_plot

logical. If TRUE, the plot will be shown.

height

: String. Default to "100%". The height of the network in pixels or as a percentage.

width

: String. Default to "100%". The width of the network in pixels or as a percentage.

export_type

Type of export. One of "png" (default), "jpeg" or "pdf".

percent

Percent skill value.

title

Title.

file

Data file path.

types

Subset the `Type` column.

label_alpha

numeric. The alpha value for the labels.

fill_alpha

numeric. The alpha value for the fill.

polar

logical. If TRUE, the plot will be polar.

...

one or more R objects, to be converted to character vectors.

Value

Formatted data.

Functions

  • build_title(): build_

  • build_toc(): build_

  • build_footer(): build_

  • build_summary(): build_

  • build_network(): build_

  • build_skill_bars(): build_

  • build_skills_plot(): build_