run_sample_limma_de: A function that runs a sample limma-voom DE workflow

Description Usage Arguments Value Examples

View source: R/de_analysis.R

Description

This wrapper function uses all the functions within this function and strings them together in a sample workflow. Currently only 'limma' is supported.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
run_sample_limma_de(
  raw_counts,
  metadata,
  .metadata_var,
  .design_vars,
  contrastcond1,
  contrastcond2,
  .cols_to_remove = NULL,
  .filter_method = "edgeR"
)

Arguments

raw_counts

cleaned dataframe of counts, rows should be gene IDs, columns should be samples, cells should only contain counts

metadata

cleaned metadata for RNAseq data

.metadata_var

column of sample identifier that user expects to match with count_matrix

contrastcond1

control var

contrastcond2

experimentl var

.filter_method

Please refer to filter_genes for more information.

cols_to_remove

vector of column numbers that do not correspond to a sample, necessary to identify for downstream functions

.design_var

a character vector of variables to include in the model these should be case-specific and match the variable names in the metadata

Value

a 'tbl'

Examples

1
2
3
4
5
6
7
8
9
cond_df <- tibble(cond1 = c("a1", "a2", "a3"), cond2 = c("b1", "b2", "b3"))

map2(cond_df$cond1, cond_df$cond2, ~run_sample_limma_de(
my_counts,
my_metadata,
my_variable,
my_design_variable,
.x,
.y))

latlio/tidyde documentation built on Dec. 21, 2021, 9:40 a.m.