Learn R Programming

qmethod (version 1.3.0)

qzscores: Q methodology: z-scores from loadings

Description

Calculates factor characteristics, z-scores, and factor scores, provided a matrix of loadings and a matrix of (manually or automatically) flagged Q-sorts.

Usage

qzscores(dataset, nfactors, loa, flagged, forced = TRUE, distribution = NULL)

Arguments

dataset
a matrix or a data frame containing raw data, with statements as rows, Q-sorts as columns, and the column scores in the distribution in each cell.
nfactors
number of factors to extract.
loa
matrix or data frame of nqsorts rows and nfactors columns, with values of factor loadings for Q-sorts, calculated using, e.g., principal(...)$loadings.
flagged
matrix or data frame of nqsorts rows and nfactors columns, with TRUE values for the Q-sorts that are flagged. Automatic flagging can be aplied using qflag. Manual flaggi
forced
logical; Is the distribution of items forced? Set to TRUE if all respondents ranked the items following strictly the distribution scores, and the values of the distribution are calculated automatically. Set to FALSE if respondent
distribution
logical; when forced = FALSE, the distribution has to be provided as a vector of numbers, such as c(-2, -1, -1, 0, 1, 1, 2, 2).

Value

  • Returns a list of class QmethodRes, with seven objects:
  • briefa list with the basic values of the analysis: date ("date"), number of statements ("nstat"), number of Q-sorts ("nqsort"), whether the distribution was 'forced' ("distro"), number of factors extracted ("nfactors"), type or rotation ("rotation"), method for correlation in the PCA ("cor.method"), and a summary of this information for display purposes ("info").
  • rawdataoriginal data.
  • loafactor loadings for Q-sorts.
  • flaggedlogical dataframe of flagged Q-sorts.
  • zscstatements z-scores.
  • zsc_nstatements rounded scores, rounded to the values in the first row of the original dataset.
  • f_charfactor characteristics obtained from qfcharact.

Details

In order to implement manual flagging, use a manually created data frame for flagged. See an example of code to perform manual flagging or to manipulate the loadings in https://github.com/aiorazabala/qmethod/wiki/Advanced-analysis.

The loadings from principal(...)$loadings can be explored to decide upon flagging. The loa data frame should have Q-sorts as rows, and factors as columns, where TRUE are the flagged Q-sorts.

References

Brown, S. R., 1980 Political subjectivity: Applications of Q methodology in political science, New Haven, CT: Yale University Press.

See further references on the methodology in qmethod-package.

Examples

Run this code
data(lipset)
library(psych)
loa <- as.data.frame(unclass(principal(lipset[[1]], 
                     nfactors = 3, rotate = "varimax")$loadings))
flagged <- qflag(nstat = 33, loa = loa)
qmzsc <- qzscores(lipset[[1]], nfactors = 3, flagged = flagged, loa = loa)
qmzsc # Show results

Run the code above in your browser using DataLab