mirror of
https://github.com/agdamsbo/REDCapCAST.git
synced 2024-11-22 05:20:23 +01:00
data handling specific to repeated and/or longitudinal projects as been wrapped in if statement to allow handling of simple projects and just split instruments
This commit is contained in:
parent
5979b972e1
commit
7c211250d8
@ -92,13 +92,13 @@ REDCap_split <- function(records,
|
||||
metadata <-
|
||||
as.data.frame(process_user_input(metadata))
|
||||
|
||||
# Process repeat instrument names to match the redcap naming
|
||||
records$redcap_repeat_instrument <- clean_redcap_name(records$redcap_repeat_instrument)
|
||||
|
||||
|
||||
# Get the variable names in the dataset
|
||||
vars_in_data <- names(records)
|
||||
|
||||
# Process repeat instrument names to match the redcap naming
|
||||
if (is.repeated_longitudinal(records)){
|
||||
records$redcap_repeat_instrument <- clean_redcap_name(records$redcap_repeat_instrument)
|
||||
|
||||
# Match arg for forms
|
||||
forms <- match.arg(forms, c("repeating", "all"))
|
||||
|
||||
@ -116,6 +116,7 @@ REDCap_split <- function(records,
|
||||
as.character(records$redcap_repeat_instrument)
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
# Standardize variable names for metadata
|
||||
# names(metadata) <- metadata_names
|
||||
@ -198,3 +199,4 @@ REDCap_split <- function(records,
|
||||
out
|
||||
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user