View source: R/RandomWalkRepeats.R
norm_colsum | R Documentation |
Function to normalize adjacency matrix by dividing each value by the colsum.
norm_colsum(w)
w |
The adjacency matrix of a given graph in sparse format - dgCMatrix |
input matrix, normalized by column sums
# 1) Normalize by column sum on a simple matrix
v1 = (c(1,1,1,0))
v2 = c(0,0,0,1)
v3 = c(1,1,1,0)
v4 = c(0,0,0,1)
w = matrix(data = c(v1,v2,v3,v4), ncol = 4, nrow = 4)
norm_colsum(w)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.