![]() | Content Disclaimer Copyright @2020. All Rights Reserved. |
Links : Home Index (Subjects) Contact StatsToDo |
Explanations and References
The main Cronbach Alpha program is presented in CronbachAlpha.php. This page provides 4 programs related to sample size for Cronbach's Alpha
Javascript Program
The pilot study and sample size estimation are used in the planning stage of a research projecr. The sample size estimate is used when the researcher has some backgorund information for the estimate. In a completely new project, where the environment of the project is unknown, the pilot study is required to compare the outcomes of different sample size, and determine when further increase in sample size no longer further improves the confidnce interval in a meaningful way The power estimate and confidence interval are carried out at the end of a project, using the data already collected. The power estimate provides an index whether the sample size was adequate for the requirements of the model. The confidence intrval provides an estimate of the precision of the Alpha thus obtained. One and two tail models The programs provides results in both the one and two tail model. The two tail model is commonly presented, and this describes the range of Alpha for precision estimates and for comparison with other data. In many cases, when Cronbach Alpha is used as a tool during the development of a multivariate measurement (such as when Factor Analysis or Multiple Regression is used), the researcher merely wish to know if a minimum value of Alpha can be achieved by the model. In these circumstances, the one tail model is more appropriate as this requires a smaller sample size. ReferencesBonett D G (2002) Sample Size Requirements for Testing and Estimating Coefficient Alpha Journal of Educational and Behavioral Statisitcs 27: 335-340Duhachek A and Iacobucci D (2004) Alpha's Standard Error (ASE): An Accurate and Precise Confidence Interval Estimate. Journal of Applied Psychology Vol. 89, No. 5, 792-808 Johanson GA and Brooks GP (2010) Initial Scale Development: Sample Size for Pilot Studies. Educational and Psychological Measurement Vol.70,Iss.3;p.394-400
Sample Size# Program 1: Sample size # subroutine functions to calculate delta, and ssiz (1 and 2 tail) ssAlpha <- function(alpha, beta, k, calpha, ralpha, tail) # alpha and beta Type I & II error { # k= number of items r alpha = proposed alpha calpha= hypothetical alpha delta = (1 - ralpha) / (1 - calpha) za = qnorm(alpha/tail) zb = qnorm(beta) n = ceiling((2 * k/(k - 1)) * (za + zb)^2 / log(delta)**2 + 2) ar <- c(delta,n) return (ar) } # Main program # Sig = Probability of Type I Error # Power = 1 - Probability of Type II Error # k = number of items # Alpha = Cronbach Alpha to detect # Refalpha = reference alpha for comparison (0 unless specified otherwise) dat = (" Sig Power k Alpha Refalpha 0.05 0.80 5 0.7 0.0 0.01 0.95 5 0.7 0.0 0.05 0.80 7 0.8 0.0 0.01 0.95 7 0.8 0.0 ") df <- read.table(textConnection(dat),header=TRUE) # conversion to data frame df # optional display of input data delta <- vector() ssiz1tail <- vector() ssiz2tail <- vector() for(i in 1 : nrow(df)) { sig = df$Sig[i] beta = 1 - df$Power[i] k = df$k[i] calpha = df$Alpha[i] ralpha = df$Refalpha[i] ssAr <- ssAlpha(sig,beta,k,calpha,ralpha,1) delta <- append(delta, ssAr[1]) ssiz1tail <- append(ssiz1tail,ssAr[2]) ssAr <- ssAlpha(sig,beta,k,calpha,ralpha,2) ssiz2tail <- append(ssiz2tail,ssAr[2]) } delta ssiz1tail ssiz2tail df$Delta <- delta df$ssiz1Tail <- ssiz1tail df$ssiz2Tail <- ssiz2tail df # show input data and ssiz resultsResults are as follows > df # show input data and ssiz results Sig Power k Alpha Refalpha Delta ssiz1Tail ssiz2Tail 1 0.05 0.80 5 0.7 0 3.333333 13 16 2 0.01 0.95 5 0.7 0 3.333333 30 33 3 0.05 0.80 7 0.8 0 5.000000 8 10 4 0.01 0.95 7 0.8 0 5.000000 17 19 Power# Program 2 Power # subroutine betaAlpha <- function (alpha,n,k,calpha,ralpha,tail) # alpha Type I error { # k= number of items r alpha = proposed alpha calpha= hypothetical alpha delta = (1 - ralpha) / (1 - calpha) za = abs(qnorm(alpha/tail)) zb = log(delta) / sqrt(2 * k/((k - 1) * (n - 2))) - za pw = pnorm(abs(zb)) ar <- c(delta,pw) return (ar) } # Main Power Program # Sig = Probability of Type I Error # n = sample size # k = number of items # Alpha = Cronbach Alpha to detect # Refalpha = reference alpha for comparison (0 unless specified otherwise) dat = (" Sig n k Alpha Refalpha 0.05 16 5 0.7 0.0 0.01 33 5 0.7 0.0 0.05 10 7 0.8 0.0 0.01 19 7 0.8 0.0 ") df <- read.table(textConnection(dat),header=TRUE) # conversion to data frame df # optional display of input data delta <- vector() pw1tail <- vector() pw2tail <- vector() for(i in 1 : nrow(df)) { alpha = df$Sig[i] n = df$n[i] k = df$k[i] calpha = df$Alpha[i] rAlpha = df$Rfalpha[i] resAr <- betaAlpha(alpha,n,k,calpha,ralpha,1) delta <- append(delta, resAr[1]) pw1tail <- append(pw1tail, resAr[2]) resAr <- betaAlpha(alpha,n,k,calpha,ralpha,2) pw2tail <- append(pw2tail, resAr[2]) } df$Delta <- delta df$Pw1tail <- pw1tail df$Pw2tail <- pw2tail df # display input data and power resultsThe results of power analysis are > df # display input data and power results Sig n k Alpha Refalpha Delta Pw1tail Pw2tail 1 0.05 16 5 0.7 0 3.333333 0.8857566 0.8130403 2 0.01 33 5 0.7 0 3.333333 0.9721438 0.9519234 3 0.05 10 7 0.8 0 5.000000 0.9091021 0.8461680 4 0.01 19 7 0.8 0 5.000000 0.9781969 0.9615009 Confidence Intervals# Program 3 Confidence Interval # subroutine function ciAlpha <- function(pc,n,k,calpha,tail) # pc = percent ci { # k= number of items cralpha = proposed alpha za = abs(qnorm((1 - pc / 100) / tail)) ll = 1 - exp(log(1 - calpha) + za * sqrt(2 * k / ((k - 1) * (n - 2)))) ul = 1 - exp(log(1 - calpha) - za * sqrt(2 * k / ((k - 1) * (n - 2)))) ar <- c(ll,ul) return (ar) } # Main Program # Pc = Percent confidence (usually 95 or 99) # n = Sample size usedThe results are > df # display input data and confidence interval results Pc n k Alpha Low1Tail High1Tail Low2Tail High2Tail 1 95 16 5 0.7 0.3988407 0.8502893 0.3132170 0.8689542 2 99 33 5 0.7 0.4191916 0.8450436 0.3765498 0.8556420 3 95 10 7 0.8 0.5137904 0.9177310 0.4235902 0.9306049 4 99 19 7 0.8 0.5264862 0.9155252 0.4806340 0.9229830 Pilot Studies# Pilot studies # subroutine function ciAlpha <- function(pc,n,k,calpha,tail) # pc = percent ci { # k= number of items cralpha = proposed alpha za = abs(qnorm((1 - pc / 100) / tail)) ll = 1 - exp(log(1 - calpha) + za * sqrt(2 * k / ((k - 1) * (n - 2)))) ul = 1 - exp(log(1 - calpha) - za * sqrt(2 * k / ((k - 1) * (n - 2)))) ar <- c(ll,ul) return (ar) } # Main Program # Input Data pc = 95 # percent confidence k = 5 # number of items alpha = 0.7 # Cronbach Alpha to detect intv = 5 # sample size intervals for testing maxN = 100 # maximum sample size # Vectors of results SSiz <- vector() # sample size # 1 tail CI1 <- vector() # confidence interval 1 tail Diff1 <- vector() # difference from previous row 1 tail CaseDec1 <- vector() # decrease per case 1 tail PcDec1 <- vector() # % decrease per case 1 tail # 2 tail CI2 <- vector() # confidence interval 2 tail Diff2 <- vector() # difference from previous row 2 tail CaseDec2 <- vector() # decrease per case 2 tail PcDec2 <- vector() # % decrease per case 2 tail # First row n = intv SSiz <- append(SSiz,n) # 1 tail resAr <- ciAlpha(pc,n,k,alpha,1) # ll and ul of ci 1 tail ci1 = resAr[2] - resAr[1] # ci 1 tail CI1 <- append(CI1,sprintf(ci1, fmt="%#.4f")) # confidence interval 1 tail Diff1 <- append(Diff1,"") # difference from previous row 1 tail CaseDec1 <- append(CaseDec1,"") # decrease per case 1 tail PcDec1 <- append(PcDec1,"") # % decrease per case 1 tail # 2 tail resAr <- ciAlpha(pc,n,k,alpha,2) # ll and ul of ci 2 tail ci2 = resAr[2] - resAr[1] # ci 2 tail CI2 <- append(CI2,sprintf(ci2, fmt="%#.4f")) # confidence interval 2 tail Diff2 <- append(Diff2,"") # difference from previous row 2 tail CaseDec2 <- append(CaseDec2,"") # decrease per case 2 tail PcDec2 <- append(PcDec2,"") # % decrease per case 2 tail # Subsequent rowa while(n < maxN) { n = n + intv SSiz <- append(SSiz,n) # 1 tail oldci1 = ci1 resAr <- ciAlpha(pc,n,k,alpha,1) # ll and ul of ci 1 tail ci1 = resAr[2] - resAr[1] # ci 1 tail CI1 <- append(CI1,sprintf(ci1, fmt="%#.4f")) # confidence interval 1 tail diff = oldci1 - ci1 Diff1 <- append(Diff1,sprintf(diff, fmt="%#.4f")) # difference from previous row 1 tail decpercase = diff / intv CaseDec1 <- append(CaseDec1,sprintf(decpercase, fmt="%#.4f")) # decrease per case 1 tail pcdec = decpercase / oldci1 * 100 PcDec1 <- append(PcDec1,sprintf(pcdec, fmt="%#.1f")) # % decrease per case 1 tail # 2 tail oldci2 = ci2 resAr <- ciAlpha(pc,n,k,alpha,2) # ll and ul of ci 2 tail ci2 = resAr[2] - resAr[1] # ci 2 tail CI2 <- append(CI2,sprintf(ci2, fmt="%#.4f")) # confidence interval 2 tail diff = oldci2 - ci2 Diff2 <- append(Diff2,sprintf(diff, fmt="%#.4f")) # difference from previous row 2 tail decpercase = diff / intv CaseDec2 <- append(CaseDec2,sprintf(decpercase, fmt="%#.4f")) # decrease per case 2 tail pcdec = decpercase / oldci2 * 100 PcDec2 <- append(PcDec2,sprintf(pcdec, fmt="%#.1f")) # % decrease per case 2 tail } # Combine all result vectors into single data frame for display df <- data.frame(SSiz,CI1,Diff1,CaseDec1,PcDec1,CI2,Diff2,CaseDec2,PcDec2) df # ResultsThe results are as follows. Please note:
> df # Results SSiz CI1 Diff1 CaseDec1 PcDec1 CI2 Diff2 CaseDec2 PcDec2 1 5 1.2797 1.7453 2 10 0.6328 0.6469 0.1294 10.1 0.7970 0.9482 0.1896 10.9 3 15 0.4713 0.1615 0.0323 5.1 0.5816 0.2155 0.0431 5.4 4 20 0.3913 0.0800 0.0160 3.4 0.4783 0.1033 0.0207 3.6 5 25 0.3416 0.0497 0.0099 2.5 0.4153 0.0630 0.0126 2.6 6 30 0.3069 0.0346 0.0069 2.0 0.3718 0.0434 0.0087 2.1 7 35 0.2810 0.0259 0.0052 1.7 0.3396 0.0322 0.0064 1.7 8 40 0.2607 0.0203 0.0041 1.4 0.3145 0.0251 0.0050 1.5 9 45 0.2443 0.0165 0.0033 1.3 0.2942 0.0203 0.0041 1.3 10 50 0.2306 0.0137 0.0027 1.1 0.2774 0.0168 0.0034 1.1 11 55 0.2189 0.0116 0.0023 1.0 0.2632 0.0142 0.0028 1.0 12 60 0.2089 0.0100 0.0020 0.9 0.2509 0.0122 0.0024 0.9 13 65 0.2001 0.0088 0.0018 0.8 0.2403 0.0107 0.0021 0.9 14 70 0.1924 0.0077 0.0015 0.8 0.2308 0.0094 0.0019 0.8 15 75 0.1855 0.0069 0.0014 0.7 0.2224 0.0084 0.0017 0.7 16 80 0.1793 0.0062 0.0012 0.7 0.2149 0.0075 0.0015 0.7 17 85 0.1736 0.0056 0.0011 0.6 0.2081 0.0068 0.0014 0.6 18 90 0.1685 0.0051 0.0010 0.6 0.2018 0.0062 0.0012 0.6 19 95 0.1638 0.0047 0.0009 0.6 0.1961 0.0057 0.0011 0.6 20 100 0.1594 0.0043 0.0009 0.5 0.1909 0.0052 0.0010 0.5 |