Greetings and welcome to gvsu215!
I’ve tried to keep function names simple and required arguments to a minimum to help students focus on the statistical content rather than the R code. That being said, there are some more advanced features and capabilities built into the package that you as the instructor may take advantage of if you so choose.
Different R Markdown Export Formats
This package should be able to be used in any output format using R Markdown, including HTML1, PDF2, and Word. If this is not the case, reach out to Dr. John Gabrosek or submit an issue on GitHub.
3:
Best results will come from HTML output. 4: If using PDF output,
you will want to make sure student R Markdown files have the following
in the YAML header which will allow the compiler to use the
xelatex engine. As such, you will avoid messages printing
out from every function call.
output:
pdf_document:
latex_engine: xelatex
Extra Function Arguments
Many functions in this package have extra arguments that aren’t necessary for basic function features but can allow for a little customization depending on your pedagogical approach and preferences, such as if you are focusing on data literacy or proper axis labeling. Each of the functions listed below have extra arguments, which are detailed after the function name.
-
tbl_1var(),tbl_corr(),tbl_num_sum()- The
digitsargument can be specified with an integer value for the number of digits to round to. Defaults to 3. - The
captionargument can be used to override the default caption.
- The
-
tbl_2var()- The
row_pctargument can be used to add in row percentages in each cell. - The
digitsargument can be specified with an integer value for the number of digits to round to. Defaults to 3. - The
captionargument can be used to override the default caption.
- The
-
tbl_pctile()- The
probsargument can be used to specify which percentiles are to be given. Simply pass in a vector of values between 0 and 1. - The
digitsargument can be specified with an integer value for the number of digits to round to. Defaults to 3. - The
captionargument can be used to override the default caption.
- The
-
plot_bar()- The
typeargument can be used to specify if a plot withpercents orcounts is desired. - The
fillargument can be used to choose a fill color (for a single variable plot). - The
orientargument can be used to flip the axis. Choose either “vertical” (the default) or “horizontal”. - The
dodgeargument can be used to create more rows on the x-axis labels. This can help if your labels are overlapping. Use an integer to tell how many row to create (more than 2 is not recommened for interpretatiblity). - The
titleargument can be used to override the default title. - The
...is used for other labels on the plot, namely, the x- and y-axis labels.
- The
-
plot_box()- The
fillargument can be used to choose a fill color. - The
orientargument can be used to flip the axis. Choose either “vertical” (the default) or “horizontal”. - The
titleargument can be used to override the default title. - The
...is used for other labels on the plot, namely, the x- and y-axis labels.
- The
-
plot_hist()- The
group_colsargument can be used with a grouped histogram to specify how many columns the faceted output should take up. - The
fillargument can be used to choose a fill color. - The
titleargument can be used to override the default title. - The
...is used for other labels on the plot, namely, the x- and y-axis labels.
- The
-
plot_scatter()- The
fillargument can be used to choose a fill color (for a non-grouped plot). - The
titleargument can be used to override the default title. - The
legend_titleargument can be used to override the default legend title. - The
axis_linesargument can be used to draw axis gridlines on the plot (both). - The
ls_lineargument can be set toTRUEto draw in a least squares line. - The
...is used for other labels on the plot, namely, the x- and y-axis labels.
- The
-
infer_*()- The
digitsargument can be specified with an integer value for the number of digits to round to. Defaults to 3. - The
captionargument can be used to override the default caption. - The
conf_lvlargument can be used to choose a different confidence level other than 0.95. (Not applicable toinfer_anova().)
- The