PXisM: Test according to Lindner

Description Usage Arguments Value Note Author(s) References See Also Examples

View source: R/PXisM.R

Description

Performs a test of significance according to Lindner

Usage

1
PXisM(m,n,Nt,k)

Arguments

m

Observed frequency of the observation tested

n

Marginal sums of the parameters realized in the configuration to be tested (vector)

Nt

Sample size of configurations

k

Number of parameters

Value

returns p for the test according to Linder

Note

The test according to Lindner requires the packages parallel. All other parts of cfa do not.

Author(s)

J. Harloff <oachimharloff@joachimharloff.de>

References

Lindner, K.: Eine exakte Auswertungsmethode zur Konfigurationsfrequenzanalyse [An exact procedure for the configural frequency analysis]. Psycholog Beitraege 26, 393?415 (1984)

Harloff, Joachim, An efficient algorithm for Lindners test (configural frequency analysis), Qual Quant DOI 10.1007/s11135-011-9499-9

See Also

cfa

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
# Does not work with windows since there is no parallel for it
if (require(parallel)) {
lk<-4 # number of parameters
ln<-c(59,57,59,58) # marginal sums of the parameters realized in the configuration to be tested
lNt<-116 # sample size of configurations
lm0<-16 # observed frequency of the configuration tested


# New algorithm
starttime=proc.time()
pHXsmallerequalM0<-sum(unlist(mclapply(0:lm0,PXisM,ln,lNt,lk)))
pHXequalM0<-PXisM(lm0,ln,lNt,lk)
pHlargerequalM0<-sum(unlist(mclapply(lm0: min(ln),PXisM,ln,lNt,lk)))
stoptime<-proc.time()
list(pHXsmallerequalM0=pHXsmallerequalM0,pHXequalM0=pHXequalM0,pHlargerequalM0=pHlargerequalM0,
timed.required=stoptime-starttime)

# End of the new algorithm
}

cfa documentation built on May 2, 2019, 1:46 p.m.

Related to PXisM in cfa...