explore_mutations {MixviR}R Documentation

MixviR Shiny Dashboard

Description

Open dashboard to explore mutation data generated with call_mutations().

Usage

explore_mutations(
  muts.df,
  dates = NULL,
  lineage.muts = NULL,
  read.muts.from = NULL,
  all.target.muts = FALSE
)

Arguments

muts.df

A data frame (produced by call_mutations()) storing mutation information for samples to analyze. Must contain columns SAMP_NAME, CHR, POS, GENE, ALT_ID, AF, & DP. Alternatively, the mutation data can be read in from a (tab-separated) file with the read.muts.from() argument. See also the write.mut.table argument in call_mutations().

dates

Path to optional csv file with cols "SAMP_NAME", "LOCATION", and "DATE". Sample names need to match those in the muts.df data frame created by call_mutations(). Dates should be provided in the format mmddyyyy.

lineage.muts

Path to optional csv file with required cols "Gene", "Mutation", and "Lineage" defining mutations associated with lineages of interest. See example file at "https://github.com/mikesovic/MixviR/blob/main/mutation_files/outbreak_20211202.csv". Additional columns will be ignored.

read.muts.from

An alternative to muts.df for providing mutation input. If a data frame generated by call_mutations() was previously written to a (comma separated) file (see write.mut.table in call_mutations()), the mutation data can be read in from that file by providing its path. The fields "SAMP_NAME, CHR, POS, GENE, ALT_ID, AF, DP" must be present (additional fields will be ignored).

all.target.muts

Logical to indicate whether results for all target mutations were written to the output of the call_mutations() function. See write.all.targets option in call_mutations(). Default FALSE. If TRUE, more informative sequencing depth information can be provided in the dashboard.

Value

Shiny Dashboard to Explore Data

Examples

if (interactive()) {explore_mutations(read.muts.from = system.file("extdata", 
                                                                   "sample_mutations.csv", 
                                                                   package = "MixviR"),
                                      lineage.muts = system.file("extdata", 
                                                                 "example_lineage_muts.csv", 
                                                                 package = "MixviR"))}
if (interactive()) {explore_mutations(read.muts.from = system.file("extdata", 
                                                                   "sample_mutations.csv", 
                                                                   package = "MixviR"), 
                                      dates = system.file("extdata", 
                                                          "example_location_date.csv", 
                                                          package = "MixviR"), 
                                      lineage.muts = system.file("extdata", 
                                                                 "example_lineage_muts.csv", 
                                                                 package = "MixviR"))}

[Package MixviR version 3.5.0 Index]