R/mclMultivLinLog.R

Defines functions mclMultivLinLog

mclMultivLinLog<-function(lambda,y){
   y<-apply(as.matrix(y),2,function(x)x+abs(min(x,.Machine$double.eps))+.Machine$double.eps)
   yt<- flowTrans:::linlog(y,lambda)   
   detcov<-det(cov(yt));
   partial<-y;
   partial[y<=lambda]<-1/lambda;
   partial[y>lambda]<-log(y[y>lambda]);
   partial<-apply(abs(partial),1,prod)
   logG<-sum(log(partial^2))/length(partial)
   return(log(detcov)-logG)
}

Try the flowTrans package in your browser

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

flowTrans documentation built on May 2, 2018, 2:38 a.m.