R/Qrbar.R

"Qrbar" <-
function(x)
 {
 r <- x$Rxy
 n <- x$n
 rb <- rbar(x)
 chi <- sum((((n-1)*(r-rb)^2)/(1-rb^2)^2),na.rm=TRUE)
 k <- length (x$Rxy[!(is.na(x$Rxy))])
 pval <- 1 - pchisq(chi, k-1)
 mat <- matrix(c(chi,k-1,pval),ncol=3)
 colnames(mat) <- c("CHISQ", "df", "p-val")
 return(mat)
}

Try the psychometric package in your browser

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

psychometric documentation built on Nov. 6, 2023, 1:06 a.m.