R/gfunction.the.lam.lm.R

Defines functions gfunction.the.lam.lm

# the first component in g.the.lam should be all zero
gfunction.the.lam.lm <- function(g.the, lam){
  
  n <- nrow(g.the[[1]])
  nthe <- length(g.the)
  g.the.lam <- matrix(NA, nrow = n, ncol = nthe)
  k <- 0
  for(m in g.the){
    k <- k + 1
    g.the.lam[, k] <- m %*% lam
  }
  
  g.the.lam
  
}

Try the gim package in your browser

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

gim documentation built on July 1, 2020, 6:29 p.m.