TestSingleRegion {rnaEditr} | R Documentation

## Test associations between phenotype and RNA editing levels.

### Description

Test associations between phenotype and RNA editing levels in a single site or summarized RNA editing levels in a single region.

### Usage

    TestSingleRegion(
      rnaEdit_num,
      modelPrep_ls,
      respType = c("binary", "continuous", "survival")
    )

### Arguments

`rnaEdit_num` | A named numeric vector of (summarized) RNA editing level values with sample IDs as names.
`modelPrep_ls` | A list includes `modelFormula_char` which is created by function `MakeModelFormula`, `pheno_df` which is the input phenotype data frame in `TestAssociations`, and `minSize` (minimum sample size per group to use regular logistic regression) which is created by function `CountSamplesPerGroup` when `respType` is `"binary"`.
`respType` | Type of outcome. Defaults to `"binary"`.

### Details

`minSize` is used by function `TestSingleRegion` to decide on whether to use regular logistic regression or Firth corrected logistic regression ("https://www.jstor.org/stable/2336755").

### Value

a dataframe with test statistics (`estimate, stdErr, pValue` or `coef, exp_coef, se_coef, pValue`).

### Examples

      data(rnaedit_df)

      exm_pheno <- readRDS(
        system.file(
        "extdata",
        "pheno_df.RDS",
        package = 'rnaEditr',
        mustWork = TRUE
        )
      )

      exm_model <- list(
        modelFormula_char = "age_at_diagnosis ~ rnaEditSummary",
        pheno_df = exm_pheno,
        minSize = NULL
      )

      TestSingleRegion(
        rnaEdit_num = unlist(rnaedit_df[2,]),
        modelPrep_ls = exm_model,
        respType = "continuous"
      )

[Package rnaEditr version 1.2.0 Index]