R/matr_glob.R

Defines functions matr_glob

Documented in matr_glob

matr_glob <-
function(l,type="g"){

# derive matrices
	Co = cbind(-diag(l-1),diag(l-1))
	if(type=="g"){
		Ma = cbind(lower.tri(matrix(1,l-1,l-1),diag=T),rep(0,l-1));
		Ma = rbind(Ma,1-Ma)
	}
	if(type=="l"){
		Ma = rbind(cbind(diag(l-1),rep(0,l-1)),
        		       cbind(rep(0,l-1),diag(l-1)))
	}
	out = list(Co=Co,Ma=Ma)
}

Try the MultiLCIRT package in your browser

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

MultiLCIRT documentation built on May 2, 2019, 2:38 p.m.