Description Usage Arguments Value

View source: R/swne_plotting.R

Embeds NMF factors and samples in 2 dimensions

1 2 3 4 |

`H` |
NMF factors (factors x samples) |

`SNN` |
Shared nearest neighbors matrix (or other similarity matrix) |

`alpha.exp` |
Increasing alpha.exp increases how much the NMF factors "pull" the samples |

`snn.exp` |
Decreasing snn.exp increases the effect of the similarity matrix on the embedding |

`n_pull` |
Number of factors pulling on each sample. Must be >= 3 |

`proj.method` |
Method to use for projecting factors. Currently only supports "sammon" |

`pca.red` |
Whether or not to run PCA on transposed H matrix before calculating factor distances |

`dist.use` |
Similarity function to use for calculating factor positions. Options include pearson (correlation), IC (mutual information), cosine, euclidean. |

`n.neighbors` |
Number of neighbors for UMAP factor projection |

`min.dist` |
Minimum distance for UMAP factor projection |

A list of factor (H.coords) and sample coordinates (sample.coords) in 2D

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.