- For longitudinal REDCap projects, the
redcap_events
column has been updated to give REDCap event factor levels and order for theredcap_event
andevent_name
columns - Fixed a bug where
read_redcap()
would fail for projects containing a stand-alone record ID instrument
- Added
combine_checkboxes()
analytics function- Use
combine_checkboxes()
to consolidate multiple checkbox fields in a REDCap data tibble under a single column
- Use
- Added new article vignette "Using Labelled Vectors with REDCapTidieR"
- Fixed a bug for mixed structure databases resulting in data loss when some fields had dual repeating-separately/repeating-together behavior
- Fixed a bug where partial keys taken from REDCap arms could be incorrectly specified
- Various improvements and additions with CRAN release of REDCapR 1.2.0:
event_name
added as a column to theredcap_event
column of longitudinal supertibblesguess_max
parameter inread_redcap()
default updated toInf
read_redcap(raw_or_label = "haven")
now correctly casts categorical data values to character when their type is not character or numeric.
read_redcap()
now supports instruments that follow a mixed repeating/non-repeating structure with theallow_mixed_structure
parameter- Mixed structure instruments (those with both repeating and nonrepeating elements) can be supported by setting
allow_mixed_structure
toTRUE
orgetOption("redcaptidier.allow.mixed.structure", FALSE)
.- When allowed, nonrepeating elements of mixed structure instruments will be treated as repeating elements with a single instance.
- Missing data codes from REDCap additional customization settings are now handled. Non-logical values are converted to
NA
inyesno
,truefalse
, andcheckbox
fields with a warning.- Warnings for MDCs can be silenced with
options(redcaptidier.allow.mdc = TRUE)
.
- Warnings for MDCs can be silenced with
raw_or_label
now accepts"haven"
as an option, converting categorical fields tohaven_labelled
vectors instead of factors.- A new metadata column,
form_complete_pct
, is now available when viewing the supertibble showing the percentage of a given instrument that has a form status marked as "Complete" (green) - Fixed a bug causing supertibble labels to not print correctly
This package has been considered stable for months now with no new issues reported, and so should be reflected in the major version number.
- Updated
openxlsx2
API calls to coincide with v1.0 - Internal cleaning and tidying of documentation
pkgdown
site updates- Migration of some vignettes over to articles
- Updated test suite to be compatible with REDCapR 1.2.0
- Introduces new functions
add_skimr_metadata()
andwrite_redcap_xlsx()
with supporting documentation read_redcap()
now supports Data Access Groups (DAGs)- New argument available to
read_redcap()
:export_data_access_groups
- New argument available to
- Fixed a bug where REDCapR API error messages weren't being returned from REDCapTidieR
- All deprecated functions have been officially retired and removed from the package
read_redcap()
now supports projects with repeating events which introduced a breaking change to data tibble column namesredcap_repeat_instance
is nowredcap_form_instance
redcap_event_instance
has been added to denote repeating events
- Improved error message suite:
- Helpful error message provided for various conditions related to REDCap API calls
- Helpful error messages added for checks across all exported functions
- Unexpected error messages provided with direction to submitting bug reports
- Improved error messages for label parsing
- Added
select_choices_and_calculations
exported by the REDCap API toredcap_metadata
tibble
- Improved process for adding/updating
httptest
mocks
- Fixed a bug where the
suppress_redcapr_messages
argument forread_redcap()
was not working appropriately - Fixed a bug where
read_redcap()
would fail whenselect_choices_and_calculations
was missing whitespace after commas (discovered by @camcaan) - Fixed a bug where
read_redcap()
would fail for projects with a multiple choice field having duplicate values with the same label- Added a warning when REDCapTidieR detects this
- Fixed a bug where empty rows would appear in data tibbles in longitudinal REDCap exports for events containing a mix of empty and filled forms
- Fixed a bug where the
forms
specification inread_redcap()
may lead to incorrect removal of data for databases with repeating events
- Function name changes:
read_redcap_tidy()
is nowread_redcap()
extract_table()
is nowextract_tibble()
extract_tables()
is nowextract_tibbles()
bind_table()
is nowbind_tibbles()
- All old functions are still supported and throw a deprecation warning
- Instrument/form-level metadata included in supertibble output:
redcap_form_label
: The instrument’s human-readable labelredcap_metadata
: REDCap metadata associated with the instrument (derived fromREDCapR::redcap_metadata_read()
)redcap_events
: Events and arms associated with this instrument (for longitudinal projects only)data_rows
,data_cols
: Row and column counts ofredcap_data
data_size
: Size of theredcap_data
tibble in memorydata_na_pct
: The percentage of missing data in theredcap_data
tibble
- New
make_labelled()
function that attaches variable labels using the labelled package - New arguments available
read_redcap()
:forms
: Allows reading specific instruments instead of the whole projectexport_survey_fields
: Allows for export ofredcap_survey_timestamp
andredcap_survey_identifier
columns from survey-enabled REDCap instruments (TRUE
by default)
- Improved execution time by >2.5X by optimizing internal functions
check_repeat_and_nonrepeat()
,distill_*_table_long()
, andmulti_choice_to_labels()
- New informative warning and error messages, now rendered using the cli package
- Tests and vignettes now use httptest to mock and cache REDCap API calls
- Implemented GitHub Actions link check
- Replaced deprecated
.data
pronoun in tidyselect expressions
- Fixed a bug in which similarly named variables could be duplicated under some circumstances
- Order of instruments in the supertibble is now the same as the order of instruments in REDCap
- Fixed an issue in which
extract_*()
functions under some circumstances returnedNULL
instead of the expected tibbles
- Fixed a bug where
clean_redcap()
may not correctly assign variables across instruments to their appropriate tables in cases of similar prefixes - Minor changes applied to documentation, including
README
andDESCRIPTION
files
- Addresses feedback received from CRAN
DESCRIPTION
file fixes for undirected quotation marks (e.g.REDCap
to 'REDCap')- Fix quotations in
@examples
tags forbind_tables
andextract_table
- Update
pkgdown
site
- Addresses feedback received from CRAN
DESCRIPTION
file fixes for spell check notesroxygen2
examples updated
- Introduces
read_redcap_tidy()
,bind_tables()
,extract_table()
, andextract_tables()
with documentation
GitHub Commits and Releases
- For a detailed change log, please see https://github.com/CHOP-CGTInformatics/REDCapTidieR/commits/main.
- For a list of the major releases, please see https://github.com/CHOP-CGTInformatics/REDCapTidieR/releases.