new helper functions for data labelling based on data dictionary

This commit is contained in:
Andreas Gammelgaard Damsbo 2024-11-27 09:56:32 +01:00
parent 9cae725de2
commit 80328d6e9a
No known key found for this signature in database
2 changed files with 38 additions and 0 deletions

View File

@ -0,0 +1,19 @@
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/read_redcap_tables.R
\name{apply_factor_labels}
\alias{apply_factor_labels}
\title{Preserve all factor levels from REDCap data dictionary in data export}
\usage{
apply_factor_labels(data, meta)
}
\arguments{
\item{data}{REDCap exported data set}
\item{meta}{REDCap data dictionary}
}
\value{
data.frame
}
\description{
Preserve all factor levels from REDCap data dictionary in data export
}

19
man/apply_field_label.Rd Normal file
View File

@ -0,0 +1,19 @@
% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/read_redcap_tables.R
\name{apply_field_label}
\alias{apply_field_label}
\title{Apply REDCap filed labels to data frame}
\usage{
apply_field_label(data, meta)
}
\arguments{
\item{data}{REDCap exported data set}
\item{meta}{REDCap data dictionary}
}
\value{
data.frame
}
\description{
Apply REDCap filed labels to data frame
}