R/simY_bin.R

Defines functions simY_bin

Documented in simY_bin

#' Simulate a network, i.e. a binary relational matrix
#' 
#' Simulates a network, i.e. a binary relational matrix
#' 
#' 
#' @usage simY_bin(EZ, rho)
#' @param EZ square matrix giving the expected value of the latent Z matrix
#' @param rho dyadic correlation
#' @return a square binary matrix
#' @author Peter Hoff
#' @export simY_bin
simY_bin <-
function(EZ,rho)
{
  ZS<-simZ(EZ,rho) 
  YS<-1*(ZS>0) ; diag(YS)<-NA
YS
}
pdhoff/amen documentation built on June 14, 2018, 3:20 p.m.