WOTPLY | R Documentation |
A ggnet2 plot is generated showing the connections between selected_stages from the latest time point and the clusters from previous time points . The number of columns is equal to the numbers of time points. In each column, the cluster of the corresponding time point is shown as network node. The weight of the links between clusters at time points t and t+1 reflect the weight of the transition probabilities from list_transition_matrices.
WOTPLY( list_transition_matrices, selected_stages, cluster_label, legend_time, customize_color, top_link = NULL )
list_transition_matrices |
List of transition matrices. Each matrix contains the transition probabilitiesfrom the clusters at time t (on the columns) towards the clusters at time t+1 (on the rows). The matrices can be obtain from function get_transition_matrix |
selected_stages |
Vector with the name of the clusters related to the latest time point for which we want to know the connection to clusters at previous time points. |
cluster_label |
Vector with the cluster information for all the cells from all time points. |
legend_time |
Vector with time information with length equal to the number of time points. |
customize_color |
Character vector with the name of the colour for each cluster (node) in each time point. |
top_link |
Integer.Maximum number of links to select between clusters at time t and clusters at time t+1. Links are sorted according to the weight and then only the top_link are kept. If NULL (default), all the links are kept. |
A ggnet2 plot
Gabriele Lubatti gabriele.lubatti@helmholtz-muenchen.de
https://CRAN.R-project.org/package=GGally
transition_1 <- matrix(1,ncol = 2,nrow = 2) colnames(transition_1) <- c("Stage1", "Stage2") row.names(transition_1) <- c("Stage1", "Stage2") l_t <- list((transition_1)) selected_stages <- c("Stage1") cluster_label <- c("Stage1", "Stage2") legend_time <- c("Day1", "Day2") customize_color <- c("#F8766D", "#00BFC4") WOTPLY(l_t, selected_stages, cluster_label, legend_time, customize_color)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.