R/updateL.R

Defines functions updateL

updateL <- function(R,S,Gamma,lambda2,rho){
  C <- S-R-Gamma/rho
  a <- eigen(C)
  D <- diag(a$values)
  U <- a$vectors
  pmax(D-lambda2/rho,0)
  L <- U%*%(pmax(D-lambda2/rho,0))%*%t(U)
  return(L)
}

Try the latentgraph package in your browser

Any scripts or data that you put into this service are public.

latentgraph documentation built on Dec. 15, 2020, 5:23 p.m.