Skip to contents

Working with data from Prospect

wrangle_lookups()
Wrangle the Edith database spec into a sing lookups data frame
read_prospect()
Reads in csv files as exported by Prospect
apply_labels()
Apply labels from a dataspec to a column
export_check()
Checks imported form lengths against the export note produced by prospect.

Summary tables

continuous_table()
Produce a data frame to summaries continuous variables
discrete_table()
Produce a dataframe to summarise discrete variables
missing_table()
Produce a dataframe to summarise data completeness for variables
ticked_table()
Produce a dataframe to summarise ticked variables
ae_table()
Produce a data frame to summarise adverse event data.

Functions for use with xtable

add_clines()
Adds LaTex \clines to an object of class "xtable"
add_multirow()
For use with latex summary tables
longtable_head()
For use with xtable's add.to.row when tabular.environment = "longtable"
makerow()
For use with xtable's add.to.row
merge_colnames()
For use with xtable's add.to.row when column names are repeated and should be merged.
prevent_pagebreak()
Preventing page breaks when using in long tables exported from xtable()
sanitise_percent()
Sanitise function for use with print.xtable

Other functions

diagPlot()
Diagnostic plots
file_stamp()
Produce a file name string with date-time stamp
package_info()
package_info
remove_duplicates()
For use with tables
row_to_colnames()
Tools for working with column names
colnames_to_row()
Move the column names of a data frame to a row
search_list()
Searches a list of dataframes.
split_colnames()
Tools for working with column names
stata_expand()
Function to recreate the expand function in Stata
strwrap_factor()
String wrapping for factor variables
totals()
Mutates data frame so that summary tables give totals
display_unicol() get_unicol()
Use the University of Sheffield Colour Palette
unicol
University of Sheffield Colour Palette
round0()
Rounds numbers but keeps trailing zeros
git_log()
Generates a log of git commits