Research Article
RecRWR: A Recursive Random Walk Method for Improved Identification of Diseases
Algorithm 1
Pseudocode for the RecRWR method.
Algorithm Recursive Random Walk with Restarts | Input : Adjancecy matrix A of size N × N; | Vector of size N with n seed proteins p0; | Restart probability r | Output : Sorted list of candidate diseases | (1) Let m1, …, mk be the binary vectors of length N | (2) Let W be a column normalized of the A matrix of size N × N | (3) | (4) Let p ≔ p0; | (5) Let i ≔ 1, j ≔ 1; | (6) | (7) While ((m1' * |p − pt − 1|) >= rho) | (8) Process (i, j, p) | (9) | (10) Let x ≔ top(p * diag(m1)); | (11) Output x; | (12) | (13) | (14) Process (i, j, p) | (15) If (i == j) | (16) While (j <= k) | (17) p ≔ Process (i, j, p); | (18) | (19) If (i != j) | (20) p ≔ Process (j, j, p) | (21) | (22) p ≔ p' * Wmij; | (23) Wmij ≔ diag(mi) * W * diag(mj) | (24) While ((mi' * (delta(p)) > ro) | (25) p ≔ (r * p0 + (1 − r)Wij * p); | (26) | (27) p ≔ p' * Wmij; | (28) p ≔ SelectTop(p, n); | (29) | (30) return p; |
|