im_netplot | R Documentation |
Creates and plot an igraph network from dataframe
im_netplot(df, icp_gene, cohort, Immune_phenotype, cutoff, seed = 1)
df |
A dataframe as outputted by |
icp_gene |
An optional character vector of immune checkpoints for color coding vertex. default is |
cohort |
An optional character string indicating a single TCGA disease. |
Immune_phenotype |
a character string indicating name of an immune feature. |
cutoff |
A numeric indicating quantile cut-off for absolute values of synergy scores. |
seed |
A single value, interpreted as an integer; Default: 1 (see set.seed for details). |
im_netplot uses igraph to construct and plot network from synergy score data frame. Dark red (Dark blue) vertices identify over-expression (low-expression) of Immune-checkpoint genes and orange (blue) vertices identify over-expression (low-expression) of oncogenes. up-regulations (down-regulations) of the immune phenotype are depicted as red (blue) edges. Thickness of an edge is determined by the absolute value of the score, and the size of each vertex is determined by its degree. Edges with absolute values lower that the cut-off will be removed from the graph.
cutoff=0 does not remove any edges. cutoff=1 removes all edges. Default is 0.95, which keeps scores with their absolute value higher than 0.95 quantile. seed is an integer that is the starting point from which random numbers are generated in igraph. Seed value is used for the reproducibility of plot layout. different seed numbers will generate different
A plotted igraph object showing network of synergistic (red) and antagonistic (blue) associations.
igraph
df <- im_syng_tcga(onco_gene = icp_gene_list[1:3], icp_gene = icp_gene_list[1:3], cohort = "acc") im_netplot(df, Immune_phenotype = "EMTscore")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.