vis_identifier_dim_dist {UCSCXenaShiny}R Documentation

Visualize the distribution difference of samples after Molecule Identifier dimension reduction analysis

Description

NOTE: the dataset must be dense matrix in UCSC Xena data hubs.

Usage

vis_identifier_dim_dist(
  dataset = NULL,
  ids = NULL,
  grp_df,
  samples = NULL,
  return.data = FALSE,
  DR_method = c("PCA", "UMAP", "tSNE"),
  add_margin = NULL,
  palette = "Set1"
)

Arguments

dataset

the dataset to obtain identifiers.

ids

the molecule identifiers.

grp_df

When dataset and id are all not NULL, it should be a data.frame with 2 columns.

  • The first column refers to sample ID.

  • The second column refers to groups indicated in axis X.

samples

default is NULL, can be common sample names for two datasets.

return.data

whether to reture the raw meta/matrix data (list) instead of plot

DR_method

the dimension reduction method

add_margin

the marginal plot (NULL, "density", "boxplot")

palette

the color setting of RColorBrewer

Value

a ggplot object.

Examples


library(UCSCXenaTools)
expr_dataset <- "TCGA.LUAD.sampleMap/HiSeqV2_percentile"
ids = c("TP53", "KRAS", "PTEN", "MDM2", "CDKN1A")

cli_dataset <- "TCGA.LUAD.sampleMap/LUAD_clinicalMatrix"
cli_df <- XenaGenerate(
  subset = XenaDatasets == cli_dataset
) %>%
  XenaQuery() %>%
  XenaDownload() %>%
  XenaPrepare()
grp_df = cli_df[, c("sampleID", "gender")]
vis_identifier_dim_dist(expr_dataset, ids, grp_df, DR_method="PCA")


[Package UCSCXenaShiny version 2.1.0 Index]