RandomWalkRestartMH icon indicating copy to clipboard operation
RandomWalkRestartMH copied to clipboard

possible incorrect calculation of initial prox_vector when using Tau

Open dkainer opened this issue 4 years ago • 1 comments
trafficstars

I think that the calculation of the starting prox_vector may be incorrect when the values of Tau are not 1. I am using the two small example networks (m1 and m2) from the Testthat tests to form a 2 layer multiplex network with an 8x8 super-adjacency matrix.

If I use only one Seed node (node 2) and set Tau = c(1.5, 0.5), then the initial prox_vector looks correct:

prox_vector [,1] [1,] 0.00 [2,] 0.75 [3,] 0.00 [4,] 0.00 [5,] 0.00 [6,] 0.25 [7,] 0.00 [8,] 0.00

However, if i use TWO seed nodes (nodes 2 and 3) and set Tau= c(1.5, 0.5) then the initial prox_vector looks wrong:

prox_vector [,1] [1,] 0.000 [2,] 0.375 [3,] 0.125 [4,] 0.000 [5,] 0.000 [6,] 0.375 [7,] 0.125 [8,] 0.000

It appears to be weighting each seed node WITHIN layers rather than across the layers. Is this an error or am i misunderstanding the use of Tau?

If it is an error i believe it is in the get.seed.scoresMultiplex function.

dkainer avatar Jan 27 '21 20:01 dkainer

Hi there,

Yeah, it looks like you are right. I will take a deeper look.

alberto-valdeolivas avatar Feb 04 '21 20:02 alberto-valdeolivas