R/transform.for.critFunC.R

Defines functions transform.for.critFunC

transform.for.critFunC <- function(mat){
  d <- a <- mat
  nbl <- nrow(mat)
  a[a == "dnc"] <- "com"
  d[d != "dnc"] <- NA
  d[d == "dnc"] <- "nul"
  r <- array(NA, dim = c(2, 1, nbl, nbl))
  r[1, 1,,] <- a
  r[2, 1,,] <- d
  return(r)
}

Try the nem package in your browser

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

nem documentation built on April 23, 2021, 3 p.m.