Description Usage Arguments Details See Also Examples
This function provides an interface for combining a t-SNE ordination with sample meta data from a phyloseq object.
1 2 |
physeq |
Phylogenetic sequencing data ( |
tsne_obj |
An list of class |
axes |
The axes to plot. Must be a length 2 numeric. |
color |
Character string indicating which variable in sample_data should be used as the ggplot2 color aesthetic |
shape |
Character string indicating which variable in sample_data should be used as the ggplot2 shape aesthetic |
title |
Plot title. |
justDF |
If FALSE (default) the plot will be displayed and a ggplot2 object will be returned. If TRUE a data.frame useful will be returned instead. |
This function is fashioned after the plot_ordination
function in the phyloseq package.
tsne_phyloseq
. add_tsne_to_sample_data
.
1 2 3 4 5 6 | library(phyloseq)
data("GlobalPatterns")
tsne_res <- tsne_phyloseq(GlobalPatterns, distance='wunifrac',
perplexity = 8, verbose=0, rng_seed = 3901)
plot_tsne_phyloseq(GlobalPatterns, tsne_res,
color = 'SampleType', title='t-SNE (Weighted UniFrac)')
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.