int_all_datastructure_segment {dataquieR} | R Documentation |
Wrapper function to check for segment data structure
Description
This function tests for unexpected elements and records, as well as duplicated identifiers and content. The unexpected element record check can be conducted by providing the number of expected records or an additional table with the expected records. It is possible to conduct the checks by study segments or to consider only selected segments.
Usage
int_all_datastructure_segment(
study_data,
label_col,
item_level = "item_level",
meta_data = item_level,
meta_data_v2,
segment_level,
meta_data_segment = "segment_level"
)
Arguments
study_data |
data.frame the data frame that contains the measurements |
label_col |
variable attribute the name of the column in the metadata with labels of variables |
item_level |
data.frame the data frame that contains metadata attributes of study data |
meta_data |
data.frame old name for |
meta_data_v2 |
character path to workbook like metadata file, see
|
segment_level |
data.frame alias for |
meta_data_segment |
data.frame the data frame that contains the metadata for the segment level, mandatory |
Value
a list with
-
SegmentTable
: data frame with selected check results, used for the data quality report.
Examples
## Not run:
out_segment <- int_all_datastructure_segment(
meta_data_segment = "meta_data_segment",
study_data = "ship",
meta_data = "ship_meta"
)
study_data <- cars
meta_data <- dataquieR::prep_create_meta(VAR_NAMES = c("speedx", "distx"),
DATA_TYPE = c("integer", "integer"), MISSING_LIST = "|", JUMP_LIST = "|",
STUDY_SEGMENT = c("Intro", "Ex"))
out_segment <- int_all_datastructure_segment(
meta_data_segment = "meta_data_segment",
study_data = study_data,
meta_data = meta_data
)
## End(Not run)