Skip to main content
. 2019 Aug 22;20(17):4102. doi: 10.3390/ijms20174102
Algorithm 1 DivePred algorithm for predicting the potential drug-disease associations.
Input: A drug-disease association matrix YNr×Nd and the drugs character matrix X1881×Nr, X21426×Nr, X34447×Nr, X4Nd×Nr.
Output: Drug-disease association score matrix F, where Fij is the association score for drug ri and disease dj.
  1. Randomly initialize the elements in F,H(v),W(v) (1v4) with the values between 0 and 1.

  2. While L(F(v),H(v),W(v)) not converged do

  3.  Fix W(v) and H(v), along with an update for F, using the rule:
    FijnewFij(2MY+2α3v=14H(v)T+2α4v=14A(v)F+2a4FAd)ij(2MF+8F+2α4v=14U(v)F+2a4FUd+α5B)ij
  4.  For v=1 to 4

  5.   Fix F and W(v), along with an update for H(v), using the rule:
    (Hij(v))newHij(v)(2α1W(v)TX(v)+2α3FT)ij(2α1W(v)TW(v)H(v)+α2wv4H(w)+2α3H(v))ij
  6.  End for

  7.  For v=1 to 4

  8.   Fix F and H(v), along with an update for W(v), using the rule:
    (Wij(v))newWij(v)(X(v)H(v)T)ij(W(v)H(v)H(v)T)ij  
  9.  End for

  10.  End While