RiboCrypt_app: Create RiboCrypt app

View source: R/RiboCrypt_app.R

RiboCrypt_appR Documentation

Create RiboCrypt app

Description

Create RiboCrypt app

Usage

RiboCrypt_app(
  validate.experiments = TRUE,
  options = list(launch.browser = ifelse(interactive(), TRUE, FALSE)),
  all_exp = list.experiments(validate = validate.experiments),
  browser_options = c(),
  init_tab_focus = "browser",
  metadata = NULL,
  all_exp_meta = all_exp[grep("all_samples-", name), ]
)

Arguments

validate.experiments

logical, default TRUE, set to FALSE to allow starting the app with malformed experiments, be careful will crash if you try to load that experiment!

options

list of arguments, default list("launch.browser" = ifelse(interactive(), TRUE, FALSE))

all_exp

a data.table, default: list.experiments(validate = validate.experiments). Which experiments do you want to allow your app to see, default is all in your system config path.

browser_options

named character vector of browser specific arguments:
- default_experiment : Which experiment to select, default: first one
- default_gene : Which genes to select, default: first one
- default_isoform : Which isoform to select, default: first one
- default_libs : Which libraries to select: first one, else a single string, where libs are seperated by "|", like "RFP_WT_r1|RFP_WT_r2".
- default_kmer : K-mer windowing size, default: 1
- default_frame_type : Ribo-seq line type, default: "lines"
- default_view_mode : "tx", alternative "genomic" - plot_on_start : Plot when starting, default: "FALSE"

init_tab_focus

character, default "browser". Which tab to open on init.

metadata

a path to csv or a data.table of metadata columns, must contain a "Run" column to merge IDs to ORFik experiments. It is used in the metabrowser tab for grouping of samples.

all_exp_meta

a data.table, default: all_exp[grep("all_samples-", name),]. Can also be NULL, to ignore the metabrowser completly. It is the subset of all_exp which are collections (the set of all experiments per organism), this will be fed to the metabrowser, while remaining all_exp are used in all other modules.

Value

RiboCrypt shiny app

Examples

## Default run
# RiboCrypt_app()
## Plot on start
# RiboCrypt_app(browser_options = c(plot_on_start = "TRUE"))
## Init with an experiment and gene (you must of course have the experiment)

#RiboCrypt_app(validate.experiments = FALSE,
#       browser_options = c(plot_on_start = "TRUE",
#                           default_experiment = "all_merged-Homo_sapiens_2024_8",
#                           default_gene = "ATF4-ENSG00000128272"))
#RiboCrypt_app(validate.experiments = FALSE, all_exp = all_exp,
#browser_options = c(plot_on_start = "TRUE",
#                    default_experiment = "human_all_merged_l50",
#                    default_gene = "RPL12-ENSG00000197958",
#                    default_isoform = "ENST00000361436",
#                    default_view_mode = "genomic"))
#RiboCrypt_app(validate.experiments = FALSE,
#       browser_options = c(plot_on_start = "TRUE",
#                           default_experiment = "all_merged-Saccharomyces_cerevisiae",
#                           default_gene = "EFM5-YGR001",
#                           default_view_mode = "genomic"))

m-swirski/RiboCrypt documentation built on Nov. 9, 2024, 11:40 p.m.