mstVariant {SMITIDvisu}R Documentation

mstVariant

Description

Draw Variants genotypes distances as a graph using Minimum Spanning Tree algorithm.

Usage

mstVariant(
  mat,
  prop,
  node.prop = NULL,
  width = NULL,
  height = NULL,
  elementId = NULL
)

Arguments

mat

a distance matrix between sequence of variants (interger distance no floating values)

prop

a data.frame for variants sequences proportions and count (see details)

node.prop

list of variants with proportions and time (default NULL)

width

numeric width for the area in pixels.

height

numeric hieght for the area in pixels.

elementId

the element ID where is draw

Details

mat is a simple distance matrix with interger values, row and lines contain a unique identifier of each variant sequences. prop is a data.frame where each row is a variant sequence, it have to contain in columns factor "ID", "proportion" and "count". "ID" is a unique identifier matching matrix value identifier, "proportion" is the proportions of the variant sequence and "count" the number of variant sequence in a varions set. node.prop is a list with name that matching mat identifier and prop "ID". Each list element contains a subvector time (Julian or timestamp) and value (proportions). That allow to draw variants proportions over time.

Examples

library(SMITIDvisu)
data(st)
mstV <- mstVariant(st.dist113_all,st.prop113_all, st.listTimeProp113)
## Not run:  
## export as standalone html file
htmlwidgets::saveWidget(mstV, "mstVariant.html")
browseURL("mstVariant.html")

## End(Not run)


[Package SMITIDvisu version 0.0.9 Index]