validate_associations_correlate_ctd: Validate associations: correlate CellTypeDataset

View source: R/validate_associations_correlate_ctd.R

validate_associations_correlate_ctdR Documentation

Validate associations: correlate CellTypeDataset

Description

Validate phenotype-cell type associations can making comparisons within and between results from different CellTypeDatasets.

Usage

validate_associations_correlate_ctd(
  results = load_example_results(),
  filters = NULL,
  group_var = "ctd",
  celltype_var = "cl_name",
  q_threshold = 0.05,
  ...
)

Arguments

results

The cell type-phenotype enrichment results generated by gen_results and merged together with merge_results

filters

A named list, where each element in the list is the name of a column in the data, and the vector within each element represents the values to include in the final data.

group_var

A character string specifying the column in results that contains the group variable to compare across.

celltype_var

A character string specifying the column in results that contains the cell type variable to compare across.

q_threshold

The q value threshold to subset the results by.

...

Additional arguments passed to plot_density_cor.

Examples

results <- load_example_results()[,.SD[seq(10000)],by="ctd"]
#### Across CTD ####
out1 <- validate_associations_correlate_ctd(results=results,
                                            group_var="ctd")
#### Within CTD: across developmental stages ####
filters <- list(ctd=c("HumanCellLandscape"), stage=c("Fetus","Adult"))
out2 <- validate_associations_correlate_ctd(results=results,
                                            filters=filters,
                                            group_var="stage")

neurogenomics/MultiEWCE documentation built on May 7, 2024, 1:52 p.m.