learningEpaulette: learningEpaulette

View source: R/learningEpaulette.R

learningEpauletteR Documentation

learningEpaulette

Description

Create a Galactic Polymath Learning Epaulette which is a special kind of mosaic plot showing proportion of lesson by subject. Outputs a horizontal and a vertical version for mobile

Usage

learningEpaulette(
  WD = "?",
  learningplot_correction = NULL,
  heightScalar = 0.5,
  epauletteHeight = 0.2,
  randomSeed = 101,
  saveFile = TRUE,
  destFolder,
  fileName = "GP-Learning-Epaulette",
  font_size = 8,
  width = 11,
  height = 1.6,
  dpi = 200,
  showPlot = TRUE,
  ...
)

Arguments

WD

working directory; default=getwd(); if "?" supplied, will invoke pick_lesson(). The basename of this working directory will then be used to find a match in the gp-lessons git project folder by calling get_wd_git(). It's a little roundabout, but is consistent with lookups centering on the Google Drive project working directory.

learningplot_correction

do you want to correct proportions (for learningEpaulette and learningChart) for the total possible standards in each subject? i.e. Common Core Math has a LOT more standards than C3 Social Studies. default=F, the proportions will just be raw proportions of each subject out of total standards aligned. If TRUE, this will scale proportions of subjects by the relative total proportions of standards in each subject.

heightScalar

for horizontal epaulette, multiplier for image height which affects amount of padding between label text and epaulette; default=1

epauletteHeight

relative size of the epaulette; default=0.2

randomSeed

random number for getting slightly different (but repeatable) repelled text labels

saveFile

T/F, save file or just print to screen?

destFolder

where do you want to save the folder; by default in the "assets/_learning-plots" folder, 1 level up from the working directory

fileName

expects "somefilename" for ggsave output image file

font_size

size of font in pts;default=11

width

plot width in inches

height

plot height in inches

dpi

resolution in dots per inch; by default 150

showPlot

plot to screen or just save to file? default=T

...

additional parameters for ggsave

Value

returned plot as a ggplot object; plot saved to assets/GP_Learning_Epaulette.png by default


galacticpolymath/GPpub documentation built on April 5, 2025, 6:04 p.m.