Skip to contents

Internal functions used by radqlqc.

Usage

get_qs_data(
  adsl,
  visit_format = "CYCLE",
  n_assessments = 5L,
  n_days = 1L,
  lookup = NULL,
  seed = NULL,
  na_percentage = 0,
  na_vars = list(QSORRES = c(1234, 0.2), QSSTRESC = c(1234, 0.2))
)

get_random_dates_between(from, to, visit_id)

prep_adqlqc(df)

calc_scales(adqlqc1)

derv_chgcat1(dataset)

comp_derv(dataset, percent, number)

Arguments

adsl

(data.frame)
Subject-Level Analysis Dataset (ADSL).

visit_format

(character)
Type of visit. Options are "WEEK" and "CYCLE".

n_assessments

(integer)
Number of weeks or cycles.

n_days

(integer)
Number of days in each cycle (only used if visit_format is "CYCLE").

lookup

(data.frame)
Additional parameters.

seed

(numeric)
Seed to use for reproducible random number generation.

na_percentage

(proportion)
Default percentage of values to be replaced by NA.

na_vars

(list)
A named list where the name of each element is a column name of ds. Each element of this list should be a numeric vector with two elements:

  • seed (numeric)
    The seed to be used for this element - can be NA.

  • percentage (proportion)
    Percentage of elements to be replaced with NA. If NA, na_percentage is used as a default.

from

(datetime vector)
Start date/times.

to

(datetime vector)
End date/times.

visit_id

(vector)
Visit identifiers.

df

(data.frame)
SDTM QS dataset.

adqlqc1

(data.frame)
Prepared data generated from the prep_adqlqc() function.

dataset

(data.frame)
Dataset.

percent

(numeric)
Completion - Completed at least y percent of questions, 1 record per visit

number

(numeric)
Completion - Completed at least x question(s), 1 record per visit

Value

a dataframe with SDTM questionnaire data

Data frame with new randomly generated dates variable.

data.frame

data.frame

data.frame

data.frame

Functions

  • get_qs_data(): Questionnaires EORTC QLQ-C30 V3.0 SDTM (QS)

    Function for generating random Questionnaires SDTM domain

  • get_random_dates_between(): Function for generating random dates between 2 dates

  • prep_adqlqc(): Prepare ADaM ADQLQC data, adding PARAMCD to SDTM QS data

  • calc_scales(): Scale calculation for ADQLQC data

  • derv_chgcat1(): Calculate Change from Baseline Category 1

  • comp_derv(): Completion/Compliance Data Calculation

Examples

adsl <- radsl(N = 10, study_duration = 2, seed = 1)
adqlqc <- radqlqc(adsl, seed = 1, percent = 80, number = 2)