add_sources {crossmeta} | R Documentation

## Add sample source information for meta-analysis.

### Description

User selects a tissue source for each contrast and indicates any sources that should be paired. This step is required if you would like to perform source-specific effect-size/pathway meta-analyses.

### Usage

    add_sources(diff_exprs, data_dir = getwd())

### Arguments

`diff_exprs` | Previous result of `diff_expr`, which can be reloaded using `load_diff`.
`data_dir` | String specifying directory of GSE folders.

### Details

The Sources tab is used to add a source for each contrast. To do so: click the relevant contrast rows, search for a source in the Sample source dropdown box, and then click the Add button.

The Pairs tab is used to indicate sources that should be paired (treated as the same source for subsequent effect-size and pathway meta-analyses). To do so: select at least two sources from the Paired sources dropdown box, and then click the Add button.

For each GSE, analysis results with added sources/pairs are saved in the corresponding GSE folder (in `data_dir`) that was created by `get_raw`.

### Value

Same as `diff_expr` with added slots for each GSE in `diff_exprs`:

`sources` | Named vector specifying selected sample source for each contrast. Vector names identify the contrast.
`pairs` | List of character vectors indicating tissue sources that should be treated as the same source for subsequent effect-size and pathway meta-analyses.

### Examples

    library(lydata)

    # load result of previous call to diff_expr:
    data_dir  <- system.file("extdata", package = "lydata")
    gse_names <- c("GSE9601", "GSE34817")
    anals     <- load_diff(gse_names, data_dir)

    # run shiny GUI to add tissue sources
    # anals <- add_sources(anals, data_dir)

[Package crossmeta version 1.13.0 Index]