Michael Thomas Flanagan's Java Scientific Library

Cronbach Class:     Cronbach's alpha consistency analysis

     

Last update 8 August 2012
Main Page of Michael Thomas Flanagan's Java Scientific Library

Cronbach's alpha coefficient is a measure of the relationship between the observed scores in a group of individuals responses to a set of questions (items) and the true score, i.e. the score that would be obtained if the scores were not contaminated with noise, e.g. fortuitous guessing in the absence of knowledge of the true response. A consistent set of items should minimize this difference which will be reflected in a high value for Cronbach's alpha coefficient. The errors in the scores should be random and uncorrelated with each other and the items should be tau-equivalent. In practice these requirements are rarely fully satisfied. See below for details of the calculation of Cronbach's alpha coefficient.

This class contains the methods required for performing Cronbach's alpha analysis of the internal consistency of the responses of several persons to list of queries (items), commonly referred to as an analysis of reliability. The principal methods of this class are:
Bibliography: Cronbach, L. J. (1951), Coefficient alpha and the internal structure of tests, Psychometrika, 16(3), 297-334.
Cohen, L., Manion, L. & Morrison, K, A. (2008), Research Methods in Education, 6th Edition, Routledge, London & New York, Chapter Six, Validity and reliability, pp 132-164.
Allen, K., Reed-Rhoads, T., Terry, R. A., Murphy, T. J. & Stone, A. D. (2008), Coefficient Alpha: An Engineer's Interpretation of Test Reliability, Journal of Engineering Education, 97(1), 87-94.

Spelling note: All methods in this class containing 'standardized' or 'Standardized' in their name may be spelt with an s replacing the z, i.e. as 'standardised' or 'Standardised', e.g. the method standardizedAlpha() may also be spelt standardisedAlpha() and, similarly, Curtosis and Curtoses may replace Kurtosis and Kurtoses respectively.
Statistics notes: The terms mean, standard deviation, variance and covariance used in this page and in the method names refer to the sample means, sample standard deviations, sample variances and sample covariances.
The denominator of the varaiances, covariances, standard deviations, skewnesses and kurtoses may be set as n or as n−1. See Set denominator.

Cronbach is a subclass of the superclass Scores.

See Stat class for the general statistical methods and functions, PCA class for Principal component Analysis and RankAnalysis for matrix rank analysis.

import directive: import flanagan.analysis.Cronbach;

SUMMARY OF METHODS

Constructor   public Cronbach()
Enter the data Read title, item names
and responses from text file
Enter responses
as rows per person
public void readScoresAsRowPerPersonA()
public void readScoresAsRowPerPersonA(String filename)
public void readScoresAsRowPerPersonB()
public void readScoresAsRowPerPersonB(String filename)
public void readScoresAsRowPerPersonC()
public void readScoresAsRowPerPersonC(String filename)
public void readScoresAsRowPerPersonD()
public void readScoresAsRowPerPersonD(String filename)
Enter responses
as rows per item
public void readScoresAsRowPerItemA()
public void readScoresAsRowPerItemA(Stringfilename)
public void readScoresAsRowPerItemB()
public void readScoresAsRowPerItemB(Stringfilename)
public void readScoresAsRowPerItemC()
public void readScoresAsRowPerItemC(Stringfilename)
public void readScoresAsRowPerItemD()
public void readScoresAsRowPerItemD(Stringfilename)
Enter data via program
arrays and Strings
Enter responses
as rows per person
public void enterScoresAsRowPerPerson(String[][] responses)
public void enterScoresAsRowPerPerson(double[][] responses)
public void enterScoresAsRowPerPerson(float[][] responses)
public void enterScoresAsRowPerPerson(int[][] responses)
public void enterScoresAsRowPerPerson(char[][] responses)
public void enterScoresAsRowPerPerson(boolean[][] responses)
public void enterScoresAsRowPerPerson(Matrix responses)
Enter responses
as rows per item
public void enterScoresAsRowPerItem(String[][] responses)
public void enterScoresAsRowPerItem(double[][] responses)
public void enterScoresAsRowPerItem(float[][] responses)
public void enterScoresAsRowPerItem(int[][] responses)
public void enterScoresAsRowPerItem(char[][] responses)
public void enterScoresAsRowPerItem(boolean[][] responses)
public void enterScoresAsRowPerItem(Matrix responses)
Enter title public void enterTitle(String title)
Enter item names public void enterItemNames(String[] itemNames)
Additional data entry options Suspend reading letters as numerals public void suspendLetterToNumeral()
public void letterToNumeral()
Dichotomous data pairs Reset numerical representation public void resetDichotomousYesTrue(double newYesTrue)
public void resetDichotomousNoFalse(double newNoFalse)
Get numerical representation public double getDichotomousYesTrue()
public double getDichotomousNoFalse()
Additional dichotomous data pairs public void additionalDichotomousPairs(String falseSign, String trueSign)
Missing response
('no response') handling
Deletions Persons public void setPersonDeletionPercentage(double percentage)
Items public void setItemDeletionPercentage(double percentage)
Replacements public void setMissingDataOption(int option)
Set the denominator
(variance, standard deviation etc.)
Set to n public void setDenominatortoN()
Set to n-1 public void setDenominatortoNminusOne()
Cronbachs's alpha
consistency coefficient
Raw data alpha public void rawAlpha()
Standardized data alpha public void standardizedAlpha()
Full analysis Perform and output a full analysis public void analysis()
public void analysis(String filename)
Set output file type public void setOutputFileType(int option)
Set incremented numbering of the output file public void setFileNumbering()
Remove incremented numbering of the output file public void removeFileNumbering()
Set output precision public void numberOfDecimalPlaces(int trunc)
public void numberOfDecimalPlaces(int trunc)
Scatter plots Plot of item - item responses raw data public void rawItemItemPlot(String itemName1, String itemName2)
public void rawItemItemPlot(int itemIndex1, int itemIndex2)
standardized data public void standardizedItemItemPlot(String itemName1, String itemName2)
public void standardizedItemItemPlot(int itemIndex1, int itemIndex2)
Plot of item - mean of items responses raw data public void rawItemMeansPlot(String itemName)
public void rawItemMeansPlot(int itemIndex)
standardized data public void standardizedItemMeansPlot(String itemName)
public void standardizedItemMeansPlot(int itemIndex)
Delete an item delete by name public double[][] deleteItem(String itemName)
delete by index public double[][] deleteItem(int itemIndex)
Correlation coefficients Between all items Correlation coefficient matrix public double[][] rawCorrelationCoefficients()
public double[][] standardizedCorrelationCoefficients()
Average correlation coefficient public double rawAverageCorrelationCoefficients()
public double standardizedAverageCorrelationCoefficients()
Average correlation coefficient
including item totals
public double rawAverageCorrelationCoefficientsWithTotals()
public double standardizedAverageCorrelationCoefficientsWithTotals()
Standard deviation of the correlation coefficients public double rawStandardDeviationCorrelationCoefficients()
public double standardizedStandardDeviationCorrelationCoefficients()
Standard deviation of the correlation coefficient
including item totals
public double rawStandardDeviationCorrelationCoefficientsWithTotals()
public double standardizedStandardDeviationCorrelationCoefficientsWithTotals()
Between pairs Item-item pair public double rawCorrelationCoefficient(String itemName1, String itemName2)
public double rawCorrelationCoefficient(int itemIndex1, int itemIndex2)
public double standardizedCorrelationCoefficient(String itemName1, String itemName2)
public double standardizedCorrelationCoefficient(int itemIndex1, int itemIndex2)
Item-(totals of the items) pair public double rawCorrelationCoefficient(String itemName)
public double rawCorrelationCoefficient(int itemIndex)
public double standardizedCorrelationCoefficient(String itemName)
public double standardizedCorrelationCoefficient(int itemIndex)
Covariances Between all items Covariance matrix/td> public double[][] rawCovariances()
public double[][] standardizedCovariances()
Between pairs Item-item pair public double rawCovariance(String itemName1, String itemName2)
public double rawCovariance(int itemIndex1, int itemIndex2)
public double standardizedCovariance(String itemName1, String itemName2)
public double standardizedCovariance(int itemIndex1, int itemIndex2)
Item-(totals of the items) pair public double rawCovariance(String itemName)
public double rawCovariance(int itemIndex)
public double standardizedCovariance(String itemName)
public double standardizedCovariance(int itemIndex)
Item means Mean values of all items Raw data public double[] rawItemMeans()
Standardized data public double[] standardizedItemMeans()
Mean value of an individual item Raw data public double rawItemMean(int index)
public double rawItemMean(String name)
Standardized data public double standardizedItemMean(int index)
public double standardizedItemMean(String name)
Mean value of all item means Raw data public double rawMeanOfItemMeans()
Standardized data public double standardizedMeanOfItemMeans()
Standard deviation of all item means Raw data public double rawStandardDeviationOfItemMeans()
Standardized data public double standardizedStandardDeviationOfItemMeans()
Variance of all item means Raw data public double rawVarianceOfItemMeans()
Standardized data public double standardizedVarianceOfItemMeans()
Maximum of all item means Raw data public double rawMaximumOfItemMeans()
Standardized data public double standardizedMaximumOfItemMeans()
Minimum of all item means Raw data public double rawMinimumOfItemMeans()
Standardized data public double standardizedMinimumOfItemMeans()
Range of all item means Raw data public double rawRangeOfItemMeans()
Standardized data public double standardizedRangeOfItemMeans()
Item standard deviations Standard deviations of all items Raw data public double[] rawItemStandardDeviations()
Standardized data public double[] standardizedItemStandardDeviations()
Standard deviation value of an individual item Raw data public double rawItemStandardDeviation(int index)
public double rawItemStandardDeviation(String name)
Standardized data public double standardizedItemStandardDeviation(int index)
public double standardizedItemStandardDeviation(String name)
Mean value of all item standard deviations Raw data public double rawMeanOfItemStandardDeviations()
Standardized data public double standardizedMeanOfItemStandardDeviations()
Standard deviation of all item standard deviations Raw data public double rawStandardDeviationOfItemStandardDeviations()
Standardized data public double standardizedStandardDeviationOfItemStandardDeviations()
Variance of all item standard deviations Raw data public double rawVarianceOfItemStandardDeviations()
Standardized data public double standardizedVarianceOfItemStandardDeviations()
Maximum of all item standard deviations Raw data public double rawMaximumOfItemStandardDeviations()
Standardized data public double standardizedMaximumOfItemStandardDeviations()
Minimum of all item standard deviations Raw data public double rawMinimumOfItemStandardDeviations()
Standardized data public double standardizedMinimumOfItemStandardDeviations()
Range of all item standard deviations Raw data public double rawRangeOfItemStandardDeviations()
Standardized data public double standardizedRangeOfItemStandardDeviations()
Item variances Variances of all items Raw data public double[] rawItemVariances()
Standardized data public double[] standardizedItemVariances()
Variance of an individual item Raw data public double rawItemVariance(int index)
public double rawItemVariance(String name)
Standardized data public double standardizedItemVariance(int index)
public double standardizedItemVariance(String name)
Mean value of all item variances Raw data public double rawMeanOfItemVariances()
Standardized data public double standardizedMeanOfItemVariances()
Standard deviation of all item variances Raw data public double rawVarianceOfItemVariances()
Standardized data public double standardizedVarianceOfItemVariances()
Variance of all item variances Raw data public double rawVarianceOfItemVariances()
Standardized data public double standardizedVarianceOfItemVariances()
Maximum of all item variances Raw data public double rawMaximumOfItemVariances()
Standardized data public double standardizedMaximumOfItemVariances()
Minimum of all item variances Raw data public double rawMinimumOfItemVariances()
Standardized data public double standardizedMinimumOfItemVariances()
Range of all item variances Raw data public double rawRangeOfItemVariances()
Standardized data public double standardizedRangeOfItemVariances()
Item maxima Maxima of all items Raw data public double[] rawItemMaxima()
Standardized data public double[] standardizedItemMaxima()
Maximum of an individual item Raw data public double rawItemMaximum(int index)
public double rawItemMaximum(String name)
Standardized data public double standardizedItemMaximum(int index)
public double standardizedItemMaximum(String name)
Mean value of all item maxima Raw data public double rawMeanOfItemMaxima()
Standardized data public double standardizedMeanOfItemMaxima()
Standard deviation of all item maxima Raw data public double rawVarianceOfItemMaxima()
Standardized data public double standardizedVarianceOfItemMaxima()
Variance of all item maxima Raw data public double rawVarianceOfItemMaxima()
Standardized data public double standardizedVarianceOfItemMaxima()
Maximum of all item maxima Raw data public double rawMaximumOfItemMaxima()
Standardized data public double standardizedMaximumOfItemMaxima()
Minimum of all item maxima Raw data public double rawMinimumOfItemMaxima()
Standardized data public double standardizedMinimumOfItemMaxima()
Range of all item maxima Raw data public double rawRangeOfItemMaxima()
Standardized data public double standardizedRangeOfItemMaxima()
Item minima Minima of all items Raw data public double[] rawItemMinima()
Standardized data public double[] standardizedItemMinima()
Minimum of an individual item Raw data public double rawItemMinimum(int index)
public double rawItemMinimum(String name)
Standardized data public double standardizedItemMinimum(int index)
public double standardizedItemMinimum(String name)
Mean value of all item minima Raw data public double rawMeanOfItemMinima()
Standardized data public double standardizedMeanOfItemMinima()
Standard deviation of all item minima Raw data public double rawVarianceOfItemMinima()
Standardized data public double standardizedVarianceOfItemMinima()
Variance of all item minima Raw data public double rawVarianceOfItemMinima()
Standardized data public double standardizedVarianceOfItemMinima()
Minimum of all item minima Raw data public double rawMinimumOfItemMinima()
Standardized data public double standardizedMinimumOfItemMinima()
Minimum of all item minima Raw data public double rawMinimumOfItemMinima()
Standardized data public double standardizedMinimumOfItemMinima()
Range of all item minima Raw data public double rawRangeOfItemMinima()
Standardized data public double standardizedRangeOfItemMinima()
Item ranges Ranges of all items Raw data public double[] rawItemRanges()
Standardized data public double[] standardizedItemRanges()
Range of an individual item Raw data public double rawItemRange(int index)
public double rawItemRange(String name)
Standardized data public double standardizedItemRange(int index)
public double standardizedItemRange(String name)
Mean value of all item ranges Raw data public double rawMeanOfItemRanges()
Standardized data public double standardizedMeanOfItemRanges()
Standard deviation of all item ranges Raw data public double rawVarianceOfItemRanges()
Standardized data public double standardizedVarianceOfItemRanges()
Variance of all item ranges Raw data public double rawVarianceOfItemRanges()
Standardized data public double standardizedVarianceOfItemRanges()
Minimum of all item ranges Raw data public double rawMinimumOfItemRanges()
Standardized data public double standardizedMinimumOfItemRanges()
Minimum of all item ranges Raw data public double rawMinimumOfItemRanges()
Standardized data public double standardizedMinimumOfItemRanges()
Range of all item ranges Raw data public double rawRangeOfItemRanges()
Standardized data public double standardizedRangeOfItemRanges()
Item medians Medians of all items Raw data public double[] rawItemMedians()
Standardized data public double[] standardizedItemMedians()
Median of an individual item Raw data public double rawItemMedian(int index)
public double rawItemMedian(String name)
Standardized data public double standardizedItemMedian(int index)
public double standardizedItemMedian(String name)
Mean value of all item medians Raw data public double rawMeanOfItemMedians()
Standardized data public double standardizedMeanOfItemMedians()
Standard deviation of all item medians Raw data public double rawVarianceOfItemMedians()
Standardized data public double standardizedVarianceOfItemMedians()
Variance of all item medians Raw data public double rawVarianceOfItemMedians()
Standardized data public double standardizedVarianceOfItemMedians()
Minimum of all item medians Raw data public double rawMinimumOfItemMedians()
Standardized data public double standardizedMinimumOfItemMedians()
Minimum of all item medians Raw data public double rawMinimumOfItemMedians()
Standardized data public double standardizedMinimumOfItemMedians()
Range of all item medians Raw data public double rawRangeOfItemMedians()
Standardized data public double standardizedRangeOfItemMedians()
Item totals Totals of all items Raw data public double[] rawItemTotals()
Standardized data public double[] standardizedItemTotals()
Total of an individual item Raw data public double rawItemTotal(int index)
public double rawItemTotal(String name)
Standardized data public double standardizedItemTotal(int index)
public double standardizedItemTotal(String name)
Mean value of all item totals Raw data public double rawMeanOfItemTotals()
Standardized data public double standardizedMeanOfItemTotals()
Standard deviation of all item totals Raw data public double rawVarianceOfItemTotals()
Standardized data public double standardizedVarianceOfItemTotals()
Variance of all item totals Raw data public double rawVarianceOfItemTotals()
Standardized data public double standardizedVarianceOfItemTotals()
Minimum of all item totals Raw data public double rawMinimumOfItemTotals()
Standardized data public double standardizedMinimumOfItemTotals()
Minimum of all item totals Raw data public double rawMinimumOfItemTotals()
Standardized data public double standardizedMinimumOfItemTotals()
Range of all item totals Raw data public double rawRangeOfItemTotals()
Standardized data public double standardizedRangeOfItemTotals()
Item Moment Skewness Moment skewness of all items Raw data public double[] rawItemMomentSkewnessess()
Standardized data public double[] standardizedItemMomentSkewnessess()
Moment skewness of an individual item Raw data public double rawItemMomentSkewness(int index)
public double rawItemMomentSkewness(String name)
Standardized data public double standardizedItemMomentSkewness(int index)
public double standardizedItemMomentSkewness(String name)
Item Median Skewness Median skewness of all items Raw data public double[] rawItemMedianSkewnessess()
Standardized data public double[] standardizedItemMedianSkewnessess()
Median skewness of an individual item Raw data public double rawItemMedianSkewness(int index)
public double rawItemMedianSkewness(String name)
Standardized data public double standardizedItemMedianSkewness(int index)
public double standardizedItemMedianSkewness(String name)
Item Quartile Skewness Quartile skewness of all items Raw data public double[] rawItemQuartileSkewnessess()
Standardized data public double[] standardizedItemQuartileSkewnessess()
Quartile skewness of an individual item Raw data public double rawItemQuartileSkewness(int index)
public double rawItemQuartileSkewness(String name)
Standardized data public double standardizedItemQuartileSkewness(int index)
public double standardizedItemQuartileSkewness(String name)
Item Excess Kurtosis Excess kurtoses of all items Raw data public double[] rawItemExcesskurtoses()
Standardized data public double[] standardizedItemExcesskurtoses()
Excess kurtosis of an individual item Raw data public double rawItemExcessKurtosis(int index)
public double rawItemExcessKurtosis(String name)
Standardized data public double standardizedItemExcessKurtosis(int index)
public double standardizedItemExcessKurtosis(String name)
Item Names and Indices   Names of the used items public String[] itemNames()
Item names as entered public String[] originalItemNames()
Deleted item names public String[] deletedItemNames()
Index of an item public int itemIndex(String name)
Name of an item public String itemName(int index)
Number of Items   Number of items used public int usedNumberOfItems()
Number of items entered public int originalNumberOfItems()
Number of items deleted public int numberOfDeletedItems()
Person Means Mean values of all persons Raw data public double[] rawPersonMeans()
Standardized data public double[] standardizedPersonMeans()
Mean of an individual person Raw data public double rawPersonMean(int index)
Standardized data public double standardizedPersonMean(int index)
Person Standard Deviations Standard deviations of all persons Raw data public double[] rawPersonStandardDeviations()
Standardized data public double[] standardizedPersonStandardDeviations()
Standard deviation of an individual person Raw data public double rawPersonStandardDeviation(int index)
Standardized data public double standardizedPersonStandardDeviation(int index)
Person Variances Variances of all persons Raw data public double[] rawPersonVariances()
Standardized data public double[] standardizedPersonVariances()
Variance of an individual person Raw data public double rawPersonVariance(int index)
Standardized data public double standardizedPersonVariance(int index)
Person Maxima Maxima of all persons Raw data public double[] rawPersonMaxima()
Standardized data public double[] standardizedPersonMaxima()
Maximum of an individual person Raw data public double rawPersonMaximum(int index)
Standardized data public double standardizedPersonMaximum(int index)
Person Minima Minima of all persons Raw data public double[] rawPersonMinima()
Standardized data public double[] standardizedPersonMinima()
Minimum of an individual person Raw data public double rawPersonMinimum(int index)
Standardized data public double standardizedPersonMinimum(int index)
Person Ranges Ranges of all persons Raw data public double[] rawPersonRanges()
Standardized data public double[] standardizedPersonRanges()
Range of an individual person Raw data public double rawPersonRange(int index)
Standardized data public double standardizedPersonRange(int index)
Person Totals Totals of all persons Raw data public double[] rawPersonTotals()
Standardized data public double[] standardizedPersonTotals()
Total of an individual person Raw data public double rawPersonTotal(int index)
Standardized data public double standardizedPersonTotal(int index)
Person Indices   Indices of the used persons public String[] personIndices()
Deleted person indices public String[] deletedPersonsIndices()
Number of Persons   Number of Persons used public int usedNumberOfPersons()
Number of persons entered public int originalNumberOfPersons()
Number of persons deleted public int numberOfDeletedPersons()
All responses Mean Raw data public double rawAllResponsesMean()
Standardized data public double standardizedAllResponsesMean()
Standard Deviation Raw data public double rawAllResponsesStandardDeviation()
Standardized data public double standardizedAllResponsesStandardDeviation()
Variance Raw data public double rawAllResponsesVariance()
Standardized data public double standardizedAllResponsesVariance()
Minimum Raw data public double rawAllResponsesMinimum()
Standardized data public double standardizedAllResponsesMinimum()
Maximum Raw data public double rawAllResponsesMaximum()
Standardized data public double standardizedAllResponsesMaximum()
Range Raw data public double rawAllResponsesRange()
Standardized data public double standardizedAllResponsesRange()
Total Raw data public double rawAllResponsesTotal()
Standardized data public double standardizedAllResponsesTotal()
Responses Original responses as entered public Object originalScores()
as row per item public double[][] originalScoresAsRowPerItem()
as row per person public double[][] originalScoresAsRowPerPerson()
Used responses (Raw data) as row per item public double[][] usedScoresAsRowPerItem()
as row per person public double[][] usedScoresAsRowPerPerson()
Used responses (Standardized data) as row per item public double[][] standardizedScoresAsRowPerItem()
as row per person public double[][] standardizedScoresAsRowPerPerson()
Replaced responses item name and person index of replacements public String[] indicesOfReplacedScores()
Number of responses original number public int originalTotalNumberOfScores()
number used public int usedTotalNumberOfScores()
number deleted public int numberOfDeletedScores()
number of missing responses replaced public int numberOfReplacedScores()




CONSTRUCTOR

public Cronbach()
Usage:                      Cronbach cr = new Cronbach();
Creates an instance of Cronbach.

ENTER DATA

The data may be read from a text file or entered via data arrays and Strings created within your program. The responses may be enetered as rows of responses per person or as rows of responses per item.

READ THE DATA FROM A TEXT FILE
The responses may be enetered as rows of responses per person or as rows of responses per item.

Read responses as rows per person

The responses may be read from a file of one of four formats:

Format A
readScoresAsRowPerPersonA

Title
Number of items
Number of persons
Row of item names
Matrix of scores arranged as rows
 starting with the person name
 then scores for that person
 with separators, e.g. space, comma.

details
Format B
readScoresAsRowPerPersonB

Title
Number of items
Number of persons
Row of item names
Row of person names
Matrix of scores arranged as
 row per person
 with separators, e.g. space, comma.

details
Format C
readScoresAsRowPerPersonC
Scores only

Matrix of scores arranged as
 row per person
 with separators, e.g. space, comma.

details
Format D
readScoresAsRowPerPersonD
Scores only

Matrix of single character scores arranged as
 row per person
 WITHOUT separators, e.g. 1101011

details
Replaced methods
readScoresAsRowPerPerson

Format A
public void readScoresAsRowPerPersonA()
public void readScoresAsRowPerPersonA(String filename)
Usage:                      cr.readScoresAsRowPerPersonA();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerPersonA(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataOne.txt".

The text file must be of the following format:

     data title
     number of items
     number of persons
     item names (one word each), as either a row or a column, e.g.    item1      item2  . . .   itemn
     name of person 1      response of person 1 to item 1      response of person 1 to item 2  . . .   response of person 1 to the nth item (all on one line)
     name of person 2      response of person 2 to item 1      response of person 2 to item 2  . . .   response of person 2 to the nth item (all on one line)
     . . .
     name of person m      response of person m to item 1      response of person m to item 2  . . .   response of person m to the nth item (all on one line)

where there are n items and m persons.
The item and person names must be single words. Each response may be a floating point number, an integer number, a single word or a single letter. The item names and responses may be separated from any preceding and/or any following number or word by a single space or several spaces, a comma, a tab, a semicolon, colon or end of line. All responses for a person must be on the same line. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any word or letter, prefereably a word, e.g. abs or missing, not listed above as a valid response. If it is represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
Example data file, ScoresDataOneA.txt, using spaces as separators.
Example data file, ScoresDataTwoA.txt using spaces as separators with missing responses.
Example data file, ScoresDataThreeA.txt using commas as separators and spaces for missing responses.

Format B
public void readScoresAsRowPerPersonB()
public void readScoresAsRowPerPersonB(String filename)
Usage:                      cr.readScoresAsRowPerPersonB();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerPersonB(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataOne.txt".

The text file must be of the following format:

     data title
     number of items
     number of persons
     item names (one word each), as either a row or a column, e.g.    item1      item2  . . .   itemn
     person names (one word each), as either a row or a column, e.g.    person1      person2  . . .   personm
     response of person 1 to item 1      response of person 1 to item 2  . . .   response of person 1 to the nth item (all on one line)
     response of person 2 to item 1      response of person 2 to item 2  . . .   response of person 2 to the nth item (all on one line)
     . . .
     response of person m to item 1      response of person m to item 2  . . .   response of person m to the nth item (all on one line)

where there are n items and m persons.
The item and person names must be single words. Each response may be a floating point number, an integer number, a single word or a single letter. The item names and responses may be separated from any preceding and/or any following number or word by a single space or several spaces, a comma, a tab, a semicolon, colon or end of line. All responses for a person must be on the same line. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any word or letter, prefereably a word, e.g. abs or missing, not listed above as a valid response. If it is represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
Example data file, ScoresDataOneB.txt, using spaces as separators.
Example data file, ScoresDataTwoB.txt using spaces as separators with missing responses.
Example data file, ScoresDataThreeB.txt using commas as separators and spaces for missing responses.

Format C
public void readScoresAsRowPerPersonC()
public void readScoresAsRowPerPersonC(String filename)
Usage:                      cr.readScoresAsRowPerPersonC();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerPersonC(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataOne.txt".

The text file must be of the following format:

     response of person 1 to item 1      response of person 1 to item 2  . . .   response of person 1 to the nth item (all on one line)
     response of person 2 to item 1      response of person 2 to item 2  . . .   response of person 2 to the nth item (all on one line)
     . . .
     response of person m to item 1      response of person m to item 2  . . .   response of person m to the nth item (all on one line)

where there are n items and m persons.
Each response may be a floating point number, an integer number, a single word or a single letter. The responses may be separated from any preceding and/or any following number by a single space or several spaces, a comma, a tab, a semicolon, colon or end of line. All responses for a person must be on the same line. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any word or letter, prefereably a word, e.g. abs or missing, not listed above as a valid response. If it is represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
Example data file, ScoresDataOneC.txt, using spaces as separators.
Example data file, ScoresDataTwoC.txt using spaces as separators with missing responses.
Example data file, ScoresDataThreeC.txt using commas as separators and spaces for missing responses.

Format D
public void readScoresAsRowPerPersonD()
public void readScoresAsRowPerPersonD(String filename)
Usage:                      cr.readScoresAsRowPerPersonD();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerPersonD(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataOne.txt".

The text file must be of the following format:

     response of person 1 to item 1      response of person 1 to item 2  . . .   response of person 1 to the nth item (all on one line)
     response of person 2 to item 1      response of person 2 to item 2  . . .   response of person 2 to the nth item (all on one line)
     . . .
     response of person m to item 1      response of person m to item 2  . . .   response of person m to the nth item (all on one line)

where there are n items and m persons.
Each response may be a single character, i.e. a single digit number or a single alphabetic character. The responses should NOT be separated from the preceding and/or following response by a searotor. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any letter not listed above as a valid response.
Example data file, ScoresDataOneD.txt.

Replaced methods
public void readScoresAsRowPerPerson()
public void readScoresAsRowPerPerson(String filename)
The above format A to format D methods replace the original read from file methods, readScoresAsRowPerPerson() and readScoresAsRowPerPerson(filename). The older methods have been retained for compatibility purposes and their documentation may be accessed by clicking Scores - replaced methods.

Read responses as rows per item

The responses may be read from a file of one of four formats:

Format A
readScoresAsRowPerItemA

Title
Number of items
Number of persons
Row of item names
Matrix of scores arranged as rows
 starting with the item name
 then scores for that item
 with separators, e.g. space, comma.

details
Format B
readScoresAsRowPerItemB

Title
Number of items
Number of persons
Row of item names
Row of person names
Matrix of scores arranged as
 row per item
 with separators, e.g. space, comma.

details
Format C
readScoresAsRowPerItemC
Scores only

Matrix of scores arranged as
 row per item
 with separators, e.g. space, comma.

details
Format D
readScoresAsRowPerItemD
Scores only

Matrix of single character scores arranged as
 row per item
 WITHOUT separators, e.g. 1101011

details
Replaced methods
readScoresAsRowPerItem

Format A
public void readScoresAsRowPerItemA()
public void readScoresAsRowPerItemA(String filename)
Usage:                      cr.readScoresAsRowPerItemA();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerItemA(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataTwo.txt".

The text file must be of the following format:

     data title
     number of items
     number of persons
     person names (one word each), as either a row or a column, e.g.    person1      person2  . . .   personm
     name of item 1      response to item 1 by person 1      response to item 1 by person 2  . . .   response to item 1 by the mth person (all on one line)
     name of item 2      response to item 2 by person 1      response to item 2 by person 2  . . .   response to item 2 by the mth person(all on one line)
     . . . .
     name of item n      response to item n by person 1      response to item n by person 2  . . .   response to item n by the mth person (all on one line)

where there are n items and m persons.
The item and person names must be single words. Each response may be a floating point number, an integer, a single word or a single letter. The item names and responses may be separated from any preceding and/or any following number or word by a single space or several spaces, a comma, a tab, a semicolon, colon or end of line. All responses for an item must be on the same line. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any word or letter, prefereably a word, e.g. abs or missing, not listed above as a valid response. If it is represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
Example data file, ScoresDataFourA.txt, using spaces as separators.
Example data file, ScoresDataFiveA.txt using spaces as separators with missing responses.
Example data file, ScoresDataSixA.txt using commas as separators and spaces for missing responses.

Format B
public void readScoresAsRowPerItemB()
public void readScoresAsRowPerItemB(String filename)
Usage:                      cr.readScoresAsRowPerItemB();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerItemB(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataTwo.txt".

The text file must be of the following format:

     data title
     number of items
     number of persons
     item names (one word each), as either a row or a column, e.g.    item1      item2  . . .   itemn
     person names (one word each), as either a row or a column, e.g.    person1      person2  . . .   personm
     response to item 1 by person 1      response to item 1 by person 2  . . .   response to item 1 by the mth person (all on one line)
     response to item 2 by person 1      response to item 2 by person 2  . . .   response to item 2 by the mth person(all on one line)
     . . . .
     response to item n by person 1      response to item n by person 2  . . .   response to item n by the mth person (all on one line)

where there are n items and m persons.
The item names must be single words. Each response may be a floating point number, an integer, a single word or a single letter. The item names and responses may be separated from any preceding and/or any following number or word by a single space or several spaces, a comma, a tab, a semicolon, colon or end of line. All responses for an item must be on the same line. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any word or letter, prefereably a word, e.g. abs or missing, not listed above as a valid response. If it is represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
Example data file, ScoresDataFourB.txt, using spaces as separators.
Example data file, ScoresDataFiveB.txt using spaces as separators with missing responses.
Example data file, ScoresDataSixB.txt using commas as separators and spaces for missing responses.

Format C
public void readScoresAsRowPerItemC()
public void readScoresAsRowPerItemC(String filename)
Usage:                      cr.readScoresAsRowPerItemC();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerItemC(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataTwo.txt".

The text file must be of the following format:

     response to item 1 by person 1      response to item 1 by person 2  . . .   response to item 1 by the mth person (all on one line)
     response to item 2 by person 1      response to item 2 by person 2  . . .   response to item 2 by the mth person(all on one line)
     . . . .
     response to item n by person 1      response to item n by person 2  . . .   response to item n by the mth person (all on one line)

where there are n items and m persons.
The item names must be single words. Each response may be a floating point number, an integer, a single word or a single letter. The item names and responses may be separated from any preceding and/or any following number or word by a single space or several spaces, a comma, a tab, a semicolon, colon or end of line. All responses for an item must be on the same line. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any word or letter, prefereably a word, e.g. abs or missing, not listed above as a valid response. If it is represented by a space that space MUST be preceded and followed by a comma, a tab, a semicolon, colon or end of line.
Example data file, ScoresDataOneC.txt, using spaces as separators.
Example data file, ScoresDataTwoC.txt using spaces as separators with missing responses.
Example data file, ScoresDataThreeC.txt using commas as separators and spaces for missing responses.

Format D
public void readScoresAsRowPerItemD()
public void readScoresAsRowPerItemD(String filename)
Usage:                      cr.readScoresAsRowPerItemD();
The data is read from a text (.txt) file selected via a dialogue window that will display all directories, and their files, on the user's computer and which opens, displaying the current directory, when this method is called.

Usage:                      cr.readScoresAsRowPerItemD(filename);
The data is read from the text (.txt) file filename. The file name must include its extension, e.g. .txt. It must either be in the working directory or the file name filename must also include the path to the appropriate directory, e.g. "C:\\AnalysisPrograms\\ScoresAnalyses\\ScoresDataTwo.txt".

The text file must be of the following format:

     response to item 1 by person 1      response to item 1 by person 2  . . .   response to item 1 by the mth person (all on one line)
     response to item 2 by person 1      response to item 2 by person 2  . . .   response to item 2 by the mth person(all on one line)
     . . . .
     response to item n by person 1      response to item n by person 2  . . .   response to item n by the mth person (all on one line)

where there are n items and m persons.
Each response may be a single character, i.e. a single digit number or a single alphabetic character. The responses should NOT be separated from the preceding and/or following response by a searotor. The following list shows how the recognized non-numerical responses will be converted to a numeric format.
* See
Resetting dichotomous pair representation for methods that reset the half-pair values of dichotomous pairs, e.g. for converting YES and NO to 1 and 0.
See additionalDichotomousPairs() for setting the option of reading dichotomous data with a non-numerical dichotomous pair not listed above.
A missing response may be represented by any letter not listed above as a valid response.
Example data file, ScoresDataOneD.txt.

Replaced methods
public void readScoresAsRowPerItem()
public void readScoresAsRowPerItem(String filename)
The above format A to format D methods replace the original read from file methods, readScoresAsRowPerItem() and readScoresAsRowPerItem(filename). The older methods have been retained for compatibility purposes and their documentation may be accessed by clicking Scores - replaced methods.





ENTER DATA VIA PROGRAM ARRAYS AND STRINGS
The responses may be enetered as rows of responses per person or as rows of responses per item.

Enter responses as rows per person
public void enterScoresAsRowPerPerson(String[][] responses)
public void enterScoresAsRowPerPerson(double[][] responses)
public void enterScoresAsRowPerPerson(float[][] responses)
public void enterScoresAsRowPerPerson(int[][] responses)
public void enterScoresAsRowPerPerson(char[][] responses)
public void enterScoresAsRowPerPerson(boolean[][] responses)
public void enterScoresAsRowPerPerson(Matrix responses)
Usage:                      cr.enterScoresAsRowPerPerson(responses);
The responses are entered via the two-dimension al array, responses. The array must be ordered in the following manner:

     responses[0][0] - response of person 1 to item 1      responses[0][1] - response of person 1 to item 2  . . .   responses[0][n-1] - response of person 1 to the nth item
     responses[1][0] - response of person 2 to item 1      responses[1][1] - response of person 1 to item 2  . . .   responses[1][n-1] - response of person 2 to the nth item
     . . . .
     responses[m-1][0] - response of person m to item 1      responses[m-1][1] - response of person m to item 2  . . .   responses[m-1][n-1] - response of person m to the nth item
where there are n items and m persons.
The allowed formats of the responses depends on the type of the array:




Enter responses as rows per item
public void enterScoresAsRowPerItem(String[][] responses)
public void enterScoresAsRowPerItem(double[][] responses)
public void enterScoresAsRowPerItem(float[][] responses)
public void enterScoresAsRowPerItem(int[][] responses)
public void enterScoresAsRowPerItem(char[][] responses)
public void enterScoresAsRowPerItem(boolean[][] responses)
public void enterScoresAsRowPerItem(Matrix responses)
Usage:                      cr.enterScoresAsRowPerItem(responses);
The responses are entered via the two-dimension al array, responses. The array must be ordered in the following manner:

     responses[0][0] - response to item 1 of person 1      responses[0][1] - response to item 1 of person 2  . . .   responses[0][m-1] - response to item 1 of the mth person
     responses[1][0] - response to item 2 of person 1      responses[1][1] - response to item 2 of person 2  . . .   responses[1][m-1] - response to item 2 of the mth person
     . . . .
     responses[n-1][0] - response to item n of person 1      responses[n-1][1] - response to item n of person 2  . . .   responses[n-1][m-1] - response to item n of the mth person
where there are n items and m persons.
The allowed formats of the responses depends on the type of the array:



ENTER TITLE
public void enterTitle(String title)
Usage:                      cr.enterTitle(title)
This is an optional method, for use if the responses have been entered via an array within your program. The data title is entered via the String argument title. A second line,
  Program execution initiated at the time on the date
will be automatically added to the entered title. This title is used as a header to the analysis output files.
If this method is not called, and the responses have been entered via an array within your program, a default title,
  Untitled Cronbach Analysis
  Program execution initiated at the time on the date
will be created.



ITEM NAMES
Enter the item names
public void enterItemNames(String[] names)
Usage:                      cr.enterItemNames(names)
This is an optional method, for use if the responses have been entered via an array within your program. The item names are entered via the String[] argument names. It is suggested that you use short single word descriptors as these names are used as column headers in the analysis output files.
If this method is not called, and the responses have been entered via an array within your program, an array of default names,
  item1,  item2,  item3,  item4 . . .
will be created.

Get all the entered item names
public String[] originalItemNames()
Usage:                      itemNames = cr.originalItemNames()
This method returns the item names of all the items entered, i.e. before any item deletions have been made.

Get all the item names used
public String[] itemNames()
Usage:                      itemNames = cr.itemNames()
This method returns the item names of the items used, i.e. after any item deletions have been made.

Get an person used item name
public String itemNames(int index)
Usage:                      itemName = cr.itemNames(index)
This method returns the item name of the item with the index index. NOTE!! the indices of the items starts at 1 NOT at 0.

Get the index of an item
public int itemIndex(String itemName)
Usage:                      index = cr.itemIndex(itemName)
This method returns the index of the item named itemName. NOTE!! the indices of the items starts at 1 NOT at 0.



ADDITIONAL DATA ENTRY OPTIONS

SUSPEND READING LETTERS AS NUMERALS
Suspeding the alphabetic to numerical conversion
public void suspendLetterToNumeral()
Usage:                      cr.suspendLetterToNumeral()
The default option of this class (since 18 November 2010) is that alphabetic responses are converted to numerical responses (See read and enter methods above for conversion details). Calling this method suspends these conversions.

Restoring the alphabetic to numerical conversion
public void letterToNumeral()
Usage:                      cr.letterToNumeral()
The method restores the conversion of alphabetic responses to numerical responses (See read and enter methods above for conversion details). It need only be called if such conversions have been suspended (see method immediately above) and need restoring.



DICHOTOMOUS DATA PAIRS

Reset Dichotomous Data Pair Numerical Representation
public void resetDichotomousYesTrue(double newYesTrue)
Usage:                      cr.resetDichotomousYesTrue(newYesTrue)
This method resets the numerical representation of the dichotomous half-pair responses, e.g. true, True, TRUE, yes, Yes, YES, y and Y, to the value passed as the argument newYesTrue. The default value is 1.

public void resetDichotomousNoFalse(double newNoFalse)
Usage:                      cr.resetDichotomousNoFalse(NoFalse)
This method resets the numerical representation of the dichotomous half-pair responses, e.g. false, false, FALSE, no, No, NO, n and N, to the value passed as the argument newNoFalse. The default value is -1.

Get the Dichotomous Data Pair Numerical Representations
public double getDichotomousYesTrue()
Usage:                      yvalue = cr.getDichotomousYesTrue()
This method returns the numerical value used to represent the dichotomous half-pair Yes, yes, Yes, Y, y, True, TRUE, True or any added equivalent.

public double getDichotomousNoFalse()
Usage:                      nvalue = cr.getDichotomousNoFalse()
This method returns the numerical value used to represent the dichotomous half-pair no, No, NO, n , N, false, false, FALSE or any added equivalent.

Additional Dichotomous Data Pairs
public void additionalDichotomousPairs(String falseSign, String trueSign)
Usage:                      cr.additionalDichotomousPairs(falseSign, trueSign)
This method should be called if you wish any of the above appropriate response entry methods to read dichotomous data in which the dichotomous pair is not one of the pairs already recognized by this class. The recognized pairs are (true, True or TRUE)/(false, false or FALSE), (yes, Yes, YES, y or Y)/(no, No, NO, n or N) or any numerical pair. If your pair is not one of the recognized pair enter the pair via the arguments falseSign and trueSign. Responses equal to the argument falseSign, on data processing, will be converted to -1 [default value] and those equal to trueSign will be converted to 1 [default value]. See immediately above for methods that can be called to alter the true/yes and false/no default values. This additionalDichotomousPairs method may be called if the data has been or will be read in from a text file or has been or will be entered via a String[][] array or a char[][] array.

The method public void otherDichotomousData(String falseSign, String trueSign) performs the same function as public void additionalDichotomousPairs(String falseSign, String trueSign).



MISSING RESPONSES

Missing responses ('no responses'), i.e. the failure of an person to respond to an item, may be dealt with by replacement (replacement options below), deletion of the person or deletion of an item.

DELETIONS
Persons
public void setPersonDeletionPercentage(double percentage)
Usage:                      cr.setPersonDeletionPercentage(percentage)
This method allows the setting of the percentage of 'no responses' associated with a person at which all the responses of that person will be deleted. The required percentage is entered via the argument percentage. A value of 0.0 will ensure that an person is deleted if that person misses just 1 response. A value of 100.0 ensures that no person will be deleted. The default value, i.e. the value used if this method is not called, is 0.0. Missing responses that are not deleted will be replaced (see setMissingDataOption for replacement options).

Items
public void setItemDeletionPercentage(double percentage)
Usage:                      cr.setItemDeletionPercentage(percentage)
This method allows the setting of the percentage of 'no responses' associated with an item at which all the responses of that item will be deleted. The required percentage is entered via the argument percentage. A value of 0.0 will ensure that an item is deleted if it contains only 1 missing response. A value of 100.0 ensures that no item will be deleted. The default value, i.e. the value used if this method is not called, is 100.0. Missing responses that are not deleted will be replaced (see setMissingDataOption for replacement options).

REPLACEMENTS
public void setMissingDataOption(int option)
Usage:                      cr.setMissingDataOption(option)
This method allows a choice of the replacement procedure for missing responses that have not been deleted. The option choice is entered as the integer argument option. There are 5 options:
The default option, i.e. the option used if this method is not called, is option 3. See deletions for deletion options.



SETTING THE DENOMINATOR

public void setDenominatorToN()
Usage:                      cr.setDenominatorToN();
Sets the denominator of the calculated variances, covariances, standard deviations, moment skewnesses, median skewnesses or kurtoses to the number of data points, n, e.g. a standard deviation will be calculated as

The default value of the denominator is (n − 1),

public void setDenominatorToNminusOne()
Usage:                      cr.setDenominatorToNminusOne();
Sets the denominator of the calculated variances, covariances, standard deviations, moment skewnesses, median skewnesses or kurtoses to the number of data points minus one, (n−1), e.g. a standard deviation will be calculated as

The is the default value and this method need only be called in the above method (set to n) as already been called and a reset to (n − 1) is required

CRONBACH'S ALPHA CONSISTENCY COEFFICIENT

Cronbach's alpha coefficient is a measure of the relationship between the observed scores in a group of persons responses to a set of questions (items) and the true score, i.e. the score that would be obtained if the scores were not contaminated with noise, e.g. fortuitous guessing in the absence of knowledge of the true response. A consistent set of items should minimize this difference which will be reflected in a high value for Cronbach's alpha coefficient. The errors in the scores should be random and uncorrelated with each other and the items should be tau-equivalent. In practice these requirements are rarely fully satisfied.

Cronbach's alpha consistency coefficient, α, is defined as

where s2i are the estimates of the variances of the n items and s2sum is the variance of the sum of all items. This coefficient may be returned calculated for the raw input data or calculated for data in which all the scores of each item have been standardized, i.e.

where zi,j is the standardized data response of the ith person to the jth item, xi,j is the raw data response of the ith person to the jth item, is the mean of the raw data responses in item j and sj is the standard deviation of the raw data responses in item j.

RAW DATA ALPHA CONSISTENCY COEFFICIENT
public double rawAlpha()
Usage:                      rawAlpha = cr.rawAlpha()
This method returns Cronbach's alpha consistency coefficient, α, calculated using the raw data responses. The coefficient, α, is calculated as:

where xi,j is the response of the ith person to the jth item, m is the number of persons and n is the number of items.

STANDARDIZED DATA ALPHA CONSISTENCY COEFFICIENT
public double standardizedAlpha()
Usage:                      standardizedAlpha = cr.standardizedAlpha()
This method returns Cronbach's alpha consistency coefficient, α calculated using the standardized data responses. The coefficient, α, is calculated as:

where is the average off all Pearson correlation coefficients between items, ri,j is the correlation coefficient between item i and item j and n is the number of items.



FULL ANALYSIS WITH OUTPUT TO A FILE

Perform analysis and output the results to a file
public void analysis(String filename)
public void analysis()
Usage:                      cr.analysis(filename)
This method performs a full analysis (details below) and writes the results to a text file named filename.
If you add the ".txt" extension to the name in the the String filename the results will be written to a text file that displays the results in an easily readable format.
If you add the ".xls" extension, the results are written in a format to facilitate display by Microsoft Excel. On opening, with Microsoft Excel, a ".xls" file created by this method Microsoft Excel may ask you to verify that file is Excel readable. Click the "yes" button in the query box.
The output file will be created in the directory in which you are working unless you add a path to filename, e.g. "C:\\AnalysisPrograms\\CronbachAnalyses\\CronbachOutputOne.txt".
See setFileNumbering() for option of adding an incremented number to the filename to prevent overwriting of files.

Usage:                      cr.analysis()
This method performs a full analysis (details below) and writes the results to a text file named CronbachOutput. The default option of this method is to write to a text file that displays the results in an easily readable format. Calling the method setOutputFileType(option) allows this option to be changed to one in which the results are written in a format to facilitate display by Microsoft Excel. On opening, with Microsoft Excel, a ".xls" file created by this method Microsoft Excel may ask you to verify that file is Excel readable. Click the "yes" button in the query box.
The output file will be created in the directory in which you are working.
See setFileNumbering() for option of adding an incremented number to the filename to prevent overwriting of files.

The output file will contain the following:
A second output file is also produced that may be used as the input file for a further analysis by CronbachAnalysis. This file is the original data with the least consistent item deleted. This file will contain:
The least consistent item is chosen by a majority voting procedure applied to the raw and standardized data alpha coefficients and correlation coefficients with the item totals. If there is an even split between the raw and standardized data the standardized data decision is chosen. Commonly, all four criteria indicate the deletion of the same item.

Set output file type
public void setOutputFileType(int option)
Usage:                      cr.setOutputFileType(option)
This method allows the setting of the type of the output file. There are two options set by the argument option:

Set incremental numbering of output filename to prevent overwriting
public void setFileNumbering()
Usage:                      cr.setFileNumbering()
If this optional method is called a integer number will be added to the output file name. On the first creation of a file of the given file name the number will be 1. On further creations of a file of the same given file name the number will be incremented by 1 thus prevention overwriting of the file.

Remove incremental numbering of output filename
public void removeFileNumbering()
Usage:                      cr.removeFileNumbering()
If this method is called the incremental numbering of the output file, described in setFileNumbering() above, is removed.

Set the precision with which floating point numbers are written
public void numberOfDecimalPlaces(int trunc)
Usage:                      cr.numberOfDecimalPlaces(trunc)
This optional method sets the number of places displayed after the decimal point when floating point numbers are written to an output file. The number of places required is entered via the argument trunc. The default value is 6. The displayed number is the rounded equivalent of the stored number. If the precision of the entered data is greater than the value trunc the output method overides the trunc value and uses the maximum precision of the entered data. See immediately below (numberOfDecimalPlacesAll) for a method that sets the output precision irrespective of the input precision.

public void numberOfDecimalPlacesAll(int trunc)
Usage:                      cr.numberOfDecimalPlacesAll(trunc)
This optional method sets the number of places displayed after the decimal point when floating point numbers are written to an output file. The number of places required is entered via the argument trunc. The default value is 6. The displayed number is the rounded equivalent of the stored number. The precision set by this method is used in the output irrespective of the precision of the input data. See immediately above (numberOfDecimalPlaces) for a method that sets takes the precision of the entered data into account.



DELETE AN ITEM

public double[][] deleteItem(String itemName)
public double[][] deleteItem(int itemIndex)
Usage:                      newResponseMatrix = cr.deleteItem(itemName)
This method returns a matrix containing the entered data with the item with the name contained in the String itemName deleted. The returned matrix contains any 'no response' replacements in the remaining responses that were made in the original response matrix and will not contain any deletion made to the original data. The format of the returned matrix is responses of each item per column.

Usage:                      newResponseMatrix = cr.deleteItem(itemIndex)
This method returns a matrix containing the entered data with the item of index itemIndex deleted. The indices run from 1 to n. The returned matrix contains any 'no response' replacements in the remaining responses that were made in the original response matrix and will not contain any deletion made to the original data. The format of the returned matrix is responses of each item per column.



SCATTER PLOTS

Plot of item - item responses
public void rawItemItemPlot(String itemName1, String itemName2)
public void rawItemItemPlot(int item1Index1, int itemIndex2)
public void standardizedItemItemPlot(String itemName1, String itemName2)
public void standardizedItemItemPlot(int item1Index1, int itemIndex2)
Usage:                      cr.rawItemItemPlot(itemName1, itemName2)
Calling this method displays, in a new window, a plot of the raw data responses of the item named itemName1 against the raw data responses of the item named itemName2.

Usage:                      cr.rawItemItemPlot(itemIndex1, itemIndex2)
Calling this method displays, in a new window, a plot of the raw data responses of the item with an index itemIndex1 against the raw data responses of the item with an index itemIndex2. NOTE!! the item indices start at 1 not at 0. See Item Names for methods that return an item index or name.

Usage:                      cr.standardizedItemItemPlot(itemName1, itemName2)
Calling this method displays, in a new window, a plot of the standardized data responses of the item named itemName1 against the standardized data responses of the item named itemName2.

Usage:                      cr.standardizedItemItemPlot(itemIndex1, itemIndex2)
Calling this method displays, in a new window, a plot of the standardized data responses of the item with an index itemIndex1 against the standardized data responses of the item with an index itemIndex2. NOTE!! the item indices start at 1 not at 0. See Item Names for methods that return an item index or name.

Plot of item - means of item responses
public void rawItemMeansPlot(String itemName)
public void rawItemMeansPlot(int item1Index)
public void standardizedItemMeansPlot(String itemName)
public void standardizedItemMeansPlot(int item1Index)
Usage:                      cr.rawItemMeansPlot(itemName)
Calling this method displays, in a new window, a plot of the raw data responses of the item named itemName against the means of the raw data responses of all items.

Usage:                      cr.rawItemMeansPlot(itemIndex)
Calling this method displays, in a new window, a plot of the raw data responses of the item with an index itemIndex a against the means of the raw data responses of all items. NOTE!! the item indices start at 1 not at 0. See Item Names for methods that return an item index or name.

Usage:                      cr.standardizedItemMeansPlot(itemName)
Calling this method displays, in a new window, a plot of the standardized data responses of the item named itemName against the means of the standardized data responses of all items.

Usage:                      cr.standardizedItemMeansPlot(itemIndex)
Calling this method displays, in a new window, a plot of the standardized data responses of the item with an index itemIndex against the means of the standardized data responses of all items. NOTE!! the item indices start at 1 not at 0. See Item Names for methods that return an item index or name.





CORRELATION COEFFICIENTS

BETWEEN ALL ITEMS
Correlation Coefficient Matrix
public double[][] rawCorrelationCoefficients()
public double[][] standardizedCorrelationCoefficients()
Usage:                      corrCoeff = cr.rawCorrelationCoefficients()
This method returns an (n+1) times (n+1) matrix where n is the number of items. Rows and columns 0 to n-1 contain the correlation coefficients, for the raw data responses, between all pairs of items, e.g. corrCoeff[0][3] contains the correlation coefficient between the first item and the fourth item. Rows and columns n contain the correlation coefficients between the items and the totals of all the items, e.g. corrCoeff[1][n] contains the correlation coefficient, for the raw data responses, between the second item and the totals of all n items.

Usage:                      corrCoeff = cr.standardizedCorrelationCoefficients()
This method returns an (n+1) times (n+1) matrix where n is the number of items. Rows and columns 0 to n-1 contain the correlation coefficients, for the standardized data responses, between all pairs of items, e.g. corrCoeff[0][3] contains the correlation coefficient between the first item and the fourth item. Rows and columns n contain the correlation coefficients between the items and the totals of all the items, e.g. corrCoeff[1][n] contains the correlation coefficient, for the standardized data responses, between the second item and the totals of all n items.

Average correlation coefficient, excluding totals
public double rawAverageCorrelationCoefficients()
public double standardizedAverageCorrelationCoefficients()
Usage:                      meanCorrCoeff = cr.rawAverageCorrelationCoefficients()
This method returns, for the raw data responses, the average of all the correlation coefficients between items,

where n is the number of items and ri,j is the correlation coefficient between the ith and jth items. This method does not include, in the average, the correlation coefficients with the totals of all the items (see
below).

Usage:                      meanCorrCoeff = cr.standardizedAverageCorrelationCoefficients()
This method returns, for the standardized data responses, the average of all the correlation coefficients between items,

where n is the number of items and ri,j is the correlation coefficient between the ith and jth items. This method does not include, in the average, the correlation coefficients with the totals of all the items (see below).

Average correlation coefficient, including totals
public double rawStandardDeviationCorrelationCoefficientsWithTotals()
public double standardizedStandardDeviationCorrelationCoefficientsWithTotals()
Usage:                      meanCorrCoeff = cr.rawStandardDeviationCorrelationCoefficientsWithTotals()
This method returns, for the raw data responses, the average of all the correlation coefficients between items and the totals of all items,

where n is the number of items and ri,j, for i and j less than or equal to n is the correlation coefficient between the ith and jth items and ri,n+1 is the correlation coefficient between the ith item and the totals of all items. See
above) for exclusion of totals.

Usage:                      meanCorrCoeff = cr.standardizedStandardDeviationCorrelationCoefficientsWithTotals()
This method returns, for the standardized data responses, the average of all the correlation coefficients between items and the totals of all items,

where n is the number of items and ri,j, for i and j less than or equal to n is the correlation coefficient between the ith and jth items and ri,n+1 is the correlation coefficient between the ith item and the totals of all items. See above for exclusion of totals.

Standard deviation of the correlation coefficients, excluding totals
public double rawStandardDeviationCorrelationCoefficients()
public double standardizedStandardDeviationCorrelationCoefficients()
Usage:                      sdCorrCoeff = cr.rawStandardDeviationCorrelationCoefficients()
This method returns, for the raw data responses, the standard deviation of all the correlation coefficients between items. This method does not include, in the average, the correlation coefficients with the totals of all the items (see
below).

Usage:                      sdCorrCoeff = cr.standardizedStandardDeviationCorrelationCoefficients()
This method returns, for the standardized data responses, the standard deviation of all the correlation coefficients between items. This method does not include, in the average, the correlation coefficients with the totals of all the items (see below).

Standard deviation of the correlation coefficients, including totals
public double rawStandardDeviationCorrelationCoefficientsWithTotals()
public double standardizedStandardDeviationCorrelationCoefficientsWithTotals()
Usage:                      sdCorrCoeff = cr.rawStandardDeviationCorrelationCoefficientsWithTotals()
This method returns, for the raw data responses, the standard deviation of all the correlation coefficients between items and the totals of all items. See
above) for exclusion of totals.

Usage:                      sdCorrCoeff = cr.standardizedStandardDeviationCorrelationCoefficientsWithTotals()
This method returns, for the standardized data responses, the standard deviation of all the correlation coefficients between items and the totals of all items. See above for exclusion of totals.

BETWEEN PAIRS
Item-item pair
public double rawCorrelationCoefficient(String itemName1, String itemName2)
public double rawCorrelationCoefficient(int itemIndex1, int itemIndex2)
public double standardizedCorrelationCoefficient(String itemName1, String itemName2)
public double standardizedCorrelationCoefficient(int itemIndex1, int itemIndex2)
Usage:                      corrCoeff = cr.rawCorrelationCoefficient(itemName1, itemName2)
This method returns the correlation coefficient, for the raw data responses, between the item with the name contained in the String itemName1 and the item with the name contained in the String itemName2.

Usage:                      corrCoeff = cr.rawCorrelationCoefficient(itemIndex1, itemIndex2)
This method returns the correlation coefficient, for the raw data responses, between the item of index itemIndex1 and the item of index itemIndex2. The indices run from 1 to n.

Usage:                      corrCoeff = cr.standardizedCorrelationCoefficient(itemName1, itemName2)
This method returns the correlation coefficient, for the standardized data responses, between the item with the name contained in the String itemName1 and the item with the name contained in the String itemName2.

Usage:                      corrCoeff = cr.standardizedCorrelationCoefficient(itemIndex1, itemIndex2)
This method returns the correlation coefficient, for the standardized data responses, between the item of index itemIndex1 and the item of index itemIndex2. The indices run from 1 to n.

Item-(totals of all items) pair
public double rawCorrelationCoefficient(String itemName)
public double rawCorrelationCoefficient(int itemIndex)
public double standardizedCorrelationCoefficient(String itemName)
public double standardizedCorrelationCoefficient(int itemIndex)
Usage:                      corrCoeff = cr.rawCorrelationCoefficient(itemName)
This method returns the correlation coefficient, for the raw data responses, between the item with the name contained in the String itemName and the totals of all items.

Usage:                      corrCoeff = cr.rawCorrelationCoefficient(itemIndex)
This method returns the correlation coefficient, for the raw data responses, between the item of index itemIndex and the totals of all items. The indices run from 1 to n.

Usage:                      corrCoeff = cr.standardizedCorrelationCoefficient(itemName1)
This method returns the correlation coefficient, for the standardized data responses, between the item with the name contained in the String itemName1 and the totals of all items.

Usage:                      corrCoeff = cr.standardizedCorrelationCoefficient(itemIndex)
This method returns the correlation coefficient, for the standardized data responses, between the item of index itemIndex aand the totals of all items. The indices run from 1 to n.





COVARIANCES

BETWEEN ALL ITEMS
Covariance Matrix
public double[][] rawCovariances()
public double[][] standardizedCovariances()
Usage:                      covar = cr.rawCovariances()
This method returns an (n+1) times (n+1) matrix where n is the number of items. Rows and columns 0 to n-1 contain the covariances, for the raw data responses, between all pairs of items, e.g. corrCoeff[0][3] contains the covariance between the first item and the fourth item. Rows and columns n contain the covariances between the items and the totals of all the items, e.g. corrCoeff[1][n] contains the covariance, for the raw data responses, between the second item and the totals of all n items. The diagonal elements contain the variances, e.g. covar[2][2] contins the variance of the third item.
See Setting the denominator for covariance formulae options.

Usage:                      covar = cr.standardizedCovariances()
This method returns an (n+1) times (n+1) matrix where n is the number of items. Rows and columns 0 to n-1 contain the covariances, for the standardized data responses, between all pairs of items, e.g. corrCoeff[0][3] contains the covariance between the first item and the fourth item. Rows and columns n contain the covariances between the items and the totals of all the items, e.g. corrCoeff[1][n] contains the covariance, for the standardized data responses, between the second item and the totals of all n items. The diagonal elements contain the variances, e.g. covar[2][2] contins the variance of the third item.
See Setting the denominator for covariance formulae options.

BETWEEN PAIRS
Item-item pair
public double rawCovariance(String itemName1, String itemName2)
public double rawCovariance(int itemIndex1, int itemIndex2)
public double standardizedCovariance(String itemName1, String itemName2)
public double standardizedCovariance(int itemIndex1, int itemIndex2)
Usage:                      covar = cr.rawCovariance(itemName1, itemName2)
This method returns the covariance, for the raw data responses, between the item with the name contained in the String itemName1 and the item with the name contained in the String itemName2.

Usage:                      covar = cr.rawCovariance(itemIndex1, itemIndex2)
This method returns the covariance, for the raw data responses, between the item of index itemIndex1 and the item of index itemIndex2. The indices run from 1 to n.

Usage:                      covar = cr.standardizedCovariance(itemName1, itemName2)
This method returns the covariance, for the standardized data responses, between the item with the name contained in the String itemName1 and the item with the name contained in the String itemName2.

Usage:                      covar = cr.standardizedCovariance(itemIndex1, itemIndex2)
This method returns the covariance, for the standardized data responses, between the item of index itemIndex1 and the item of index itemIndex2. The indices run from 1 to n.

See Setting the denominator for covariance formulae options.

Item-(totals of all items) pair
public double rawCovariance(String itemName)
public double rawCovariance(int itemIndex)
public double standardizedCovariance(String itemName)
public double standardizedCovariance(int itemIndex)
Usage:                      covar = cr.rawCovariance(itemName)
This method returns the covariance, for the raw data responses, between the item with the name contained in the String itemName and the totals of all items.

Usage:                      covar = cr.rawCovariance(itemIndex)
This method returns the covariance, for the raw data responses, between the item of index itemIndex and the totals of all items. The indices run from 1 to n.

Usage:                      covar = cr.standardizedCovariance(itemName1)
This method returns the covariance, for the standardized data responses, between the item with the name contained in the String itemName1 and the totals of all items.

Usage:                      covar = cr.standardizedCovariance(itemIndex)
This method returns the covariance, for the standardized data responses, between the item of index itemIndex aand the totals of all items. The indices run from 1 to n.

See Setting the denominator for covariance formulae options.



ITEM MEANS

MEAN VALUES OF ALL ITEMS
Raw data
public double[] rawItemMeans()
Usage:                      itemMeans = cr.rawItemMeans()
This method returns the means, calculated using the raw data, of all the items. The order of items is as entered minus any deleted due to missing responses.
Standardized data
public double[] standardizedItemMeans()
Usage:                      itemMeans = cr.standardizedItemMeans()
This method returns the means, calculated using standardized data, of all the items. The order of items is as entered minus any deleted due to missing responses.

MEAN VALUE OF AN INDIVIDUAL ITEM
Raw data
public double rawItemMean(int index)
public double rawItemMean(String name)
Usage:                      itemMean = cr.rawItemMean(item)
This method returns the mean, calculated using the raw data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.
Standardized data
public double standardizedItemMean(int index)
public double standardizedItemMean(String name)
Usage:                      itemMean = cr.standardizedItemMean(item)
This method returns the mean, calculated using standardized data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.

MEAN VALUE OF ALL ITEM MEANS
Raw data
public double rawMeanOfItemMeans()
Usage:                      itemMeanOfMeans = cr.rawMeanOfItemMeans()
This method returns the mean, calculated using the raw data, of the means of all items.
Standardized data
public double standardizedMeanOfItemMeans()
Usage:                      itemMeanOfMeans = cr.standardizedMeanOfItemMeans()
This method returns the mean, calculated using standardized data, of the means of all items.

STANDARD DEVIATION OF ALL ITEM MEANS
Raw data
public double rawStandardDeviationOfItemMeans()
Usage:                      itemSdOfMeans = cr.rawStandardDeviationOfItemMeans()
This method returns the standard deviation, calculated using the raw data, of the means of all items.
Standardized data
public double[] standardizedStandardDeviationOfItemMeans()
Usage:                      itemSdOfMeans = cr.standardizedStandardDeviationOfItemMeans()
This method returns the standard deviation, calculated using standardized data, of the means of all items.

See Setting the denominator for standard deviation formulae options.

VARIANCE OF ALL ITEM MEANS
Raw data
public double rawVarianceOfItemMeans()
Usage:                      itemVarOfMeans = cr.rawVarianceOfItemMeans()
This method returns the variance, calculated using the raw data, of the means of all items.
Standardized data
public double[] standardizedVarianceOfItemMeans()
Usage:                      itemVarOfMeans = cr.standardizedVarianceOfItemMeans()
This method returns the variance, calculated using standardized data, of the means of all items.

See Setting the denominator for variance formulae options.

MAXIMUM OF ALL ITEM MEANS
Raw data
public double rawMaximumOfItemMeans()
Usage:                      itemMaxOfMeans = cr.rawMaximumOfItemMeans()
This method returns the maximum, calculated using the raw data, of the means of all items.
Standardized data
public double[] standardizedMaximumOfItemMeans()
Usage:                      itemMaxOfMeans = cr.standardizedMaximumOfItemMeans()
This method returns the maximum, calculated using standardized data, of the means of all items.

MINIMUM OF ALL ITEM MEANS
Raw data
public double rawMinimumOfItemMeans()
Usage:                      itemMinOfMeans = cr.rawMinimumOfItemMeans()
This method returns the minimum, calculated using the raw data, of the means of all items.
Standardized data
public double[] standardizedMinimumOfItemMeans()
Usage:                      itemMinOfMeans = cr.standardizedMinimumOfItemMeans()
This method returns the minimum, calculated using standardized data, of the means of all items.

RANGE OF ALL ITEM MEANS
Raw data
public double rawRangeOfItemMeans()
Usage:                      itemRangeOfMeans = cr.rawRangeOfItemMeans()
This method returns the range, calculated using the raw data, of the means of all items.
Standardized data
public double[] standardizedRangeOfItemMeans()
Usage:                      itemRangeOfMeans = cr.standardizedRangeOfItemMeans()
This method returns the range, calculated using standardized data, of the means of all items.



ITEM MOMENT SKEWNESS

The moment skewness of an item is defined as

where xi are the responses to the item in question, is the sample mean of the item and s is the sample standard deviation of the item.
The default denominator is (n−1). See Setting the denominator for methods resetting the denominator.

MOMENT SKEWNESS OF ALL ITEMS
Raw data
public double[] rawItemMomentSkewnessess()
Usage:                      skewness = cr.rawItemMomentSkewnessess()
This method returns the moment skewnesses, calculated using the raw data, of all the items. The order of items is as entered minus any deleted due to missing responses.
Standardized data
public double[] standardizedItemMomentSkewnessess() Usage:                      skewness = cr.standardizedItemMomentSkewnessess()
This method returns the moment skewnesses, calculated using standardized data, of all the items. The order of items is as entered minus any deleted due to missing responses.

MOMENT SKEWNESS OF AN INDIVIDUAL ITEM
Raw data
public double rawItemMomentSkewness(int index)
public double rawItemMomentSkewness(String name)
Usage:                      skewness = cr.rawItemMomentSkewness(item)
This method returns the moment skewness, calculated using the raw data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.
Standardized data
public double standardizedItemMomentSkewness(int index)
public double standardizedItemMomentSkewness(String name)
Usage:                      skewness = cr.standardizedItemMomentSkewness(item)
This method returns the moment skewness, calculated using standardized data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.

ITEM MEDIAN SKEWNESS (Pearson's median skewness coefficient)

The median skewness of an item is defined as

See Setting the denominator for standard deviation formulae options.

MEDIAN SKEWNESS OF ALL ITEMS
Raw data
public double[] rawItemMedianSkewnessess()
Usage:                      skewness = cr.rawItemMedianSkewnessess()
This method returns the median skewnesses, calculated using the raw data, of all the items. The order of items is as entered minus any deleted due to missing responses.
Standardized data
public double[] standardizedItemMedianSkewnessess()
Usage:                      skewness = cr.standardizedItemMedianSkewnessess()
This method returns the median skewnesses, calculated using standardized data, of all the items. The order of items is as entered minus any deleted due to missing responses.

MEDIAN SKEWNESS OF AN INDIVIDUAL ITEM
Raw data
public double rawItemMedianSkewness(int index)
public double rawItemMedianSkewness(String name)
Usage:                      skewness = cr.rawItemMedianSkewness(item)
This method returns the median skewness, calculated using the raw data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.
Standardized data
public double standardizedItemMedianSkewness(int index)
public double standardizedItemMedianSkewness(String name)
Usage:                      skewness = cr.standardizedItemMedianSkewness(item)
This method returns the median skewness, calculated using standardized data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.

ITEM QUARTILE SKEWNESS (Bowley skewness coefficient)

The quartile skewness of an item is defined as

where the Qs denote the interquartile ranges of the item.

QUARTILE SKEWNESS OF ALL ITEMS
Raw data
public double[] rawItemMedianSkewnessess()
Usage:                      skewness = cr.rawItemQuartileSkewnessess()
This method returns the quartile skewnesses, calculated using the raw data, of all the items. The order of items is as entered minus any deleted due to missing responses.
Standardized data
public double[] rawItemQuartileSkewnessess()
Usage:                      skewness = cr.standardizedItemQuartileSkewnessess()
This method returns the quartile skewnesses, calculated using standardized data, of all the items. The order of items is as entered minus any deleted due to missing responses.

QUARTILE SKEWNESS OF AN INDIVIDUAL ITEM
Raw data
public double rawItemQuartileSkewness(int index)
public double rawItemQuartileSkewness(String name)
Usage:                      skewness = cr.rawItemMedianSkewness(item)
This method returns the quartile skewness, calculated using the raw data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.
Standardized data
public double standardizedItemQuartileSkewness(int index)
public double standardizedItemQuartileSkewness(String name)
Usage:                      skewness = cr.standardizedItemMedianSkewness(item)
This method returns the quartile skewness, calculated using standardized data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.



ITEM EXCESS KURTOSIS

The excess kurtosis of an item is defined as

where xi are the responses to the item in question, is the sample mean of the item and s is the sample standard deviation opf the item, i.e. returns the kurtosis of the item minus the kurtosis of a Gaussian distribution (3.0).
The default denominator is (n−1). See Setting the denominator for methods resetting the denominator.

EXCESS KURTOSES OF ALL ITEMS
Raw data
public double[] rawItemExcessKurtoses()
Usage:                      kurtoses = cr.rawItemExcessKurtoses()
This method returns the excess kurtoses, calculated using the raw data, of all the items. The order of items is as entered minus any deleted due to missing responses.
Standardized data
public double[] standardizedItemExcesskurtoses()
Usage:                      kurtoses = cr.standardizedItemExcesskurtoses()
This method returns the excess kurtoses, calculated using standardized data, of all the items. The order of items is as entered minus any deleted due to missing responses.

EXCESS KURTOSIS OF AN INDIVIDUAL ITEM
Raw data
public double rawItemExcessKurtosis(int index)
public double rawItemExcessKurtosis(String name)
Usage:                      kurtosis = cr.rawItemExcessKurtosis(item)
This method returns the excess kurtosis, calculated using the raw data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.
Standardized data
public double standardizedItemExcessKurtosis(int index)
public double standardizedItemExcessKurtosis(String name)
Usage:                      kurtosis = cr.standardizedItemExcessKurtosis(item)
This method returns the excess kurtosis, calculated using standardized data, of an individual item. The item may be identified (argument item) by its index or its name. Note that the order of items starts at 1 and NOT 0. The order is as entered minus any deleted due to missing responses.



ITEM NAMES AND INDICES

NAMES OF THE USED ITEMS
public String[] itemNames()
Usage:                      names = cr.itemNames()
This method returns the names of the items used, i.e. after any deletions due to 'missing responses'.

NAMES OF THE ENTERED ITEMS
public String[] originalItemNames()
Usage:                      names = cr.originalItemNames()
This method returns the names of the items originally entered, i.e. before any deletions due to 'missing responses'.

NAMES OF ANY DELETED ITEMS
public String[] deletedItemsNames()
Usage:                      names = cr.deletedItemsNames()
This method returns the names of items originally entered but then deleted as part of the 'missing responses' handling. If no items have been deleted null is returned.

INDEX OF AN ITEM
public int itemIndex(String name)
Usage:                      index = cr.itemIndex(name)
This method returns the index of the item whose name is passed to the method as the argument name. NOTE the indices of names start at 1 and NOT at zero.

NAME OF AN ITEM
public String itemName(int index)
Usage:                      name = cr.itemName(index)
This method returns the name of the item whose index is passed to the method as the argument index. NOTE the indices of names start at 1 and NOT at zero.



NUMBER OF ITEMS

Number of items used
public int usedNumberOfItems()
Usage:                      num = cr.usedNumberOfItems()
This method returns the number of items used, i.e. after any deletions due to the 'missing response' handling.

Number of items entered
public int originalNumberOfItems()
Usage:                      num = cr.originalNumberOfItems()
This method returns the number of items entered, i.e. before any deletions due to the 'missing response' handling.

Number of items deleted
public int numberOfDeletedItems()
Usage:                      num = cr.numberOfDeletedItems()
This method returns the number of items deleted due to the 'missing response' handling.



PERSON INDICES

INDICES OF THE USED PERSONS
public String[] personIndices()
Usage:                      names = cr.personIndices()
This method returns the indices of the persons used, i.e. after any deletions due to 'missing responses'. NOTE the indices of the persons start at 1 and NOT at zero.

INDICES OF ANY DELETED PERSONSS
public String[] deletedPersonsIndices()
Usage:                      names = cr.deletedPersonsIndices()
This method returns the indices of items originally entered but then deleted as part of the 'missing responses' handling. NOTE the indices of the persons start at 1 and NOT at zero.



NUMBER OF PERSONS

Number of persons used
public int usedNumberOfPersons()
Usage:                      num = cr.usedNumberOfPersons()
This method returns the number of persons used, i.e. after any deletions due to the 'missing response' handling.

Number of persons entered
public int originalNumberOfPersons()
Usage:                      num = cr.originalNumberOfPersons()
This method returns the number of persons entered, i.e. before any deletions due to the 'missing response' handling.

Number of persons deleted
public int numberOfDeletedPersons()
Usage:                      num = cr.numberOfDeletedPersons()
This method returns the number of persons deleted due to the 'missing response' handling.



RESPONSES

ORIGINAL RESONSES
Responses as originally entered
public Object originalScores()
Usage:                      originalData = cr.originalScores()
This method returns the responses as originally entered, i.e. before any deletions. They are returned as a Java Object as they may have been entered as String[][], double[][], float[][], int[][], char[][], boolean[][] or Matrix. If they were originally read in from a text file the returned Object is of type String[][].

Original responses as row per item
public double[][] originalScoresAsRowPerItem()
Usage:                      originalData = cr.originalScoresAsRowPerItem()
This method returns the original responses entered rearranged as a two dimensional array of doubles orgainized as a row of responses for each item. Missing responses are returned as Double.NaN.

Original responses as row per person
public double[][] originalScoresAsRowPerPerson()
Usage:                      originalData = cr.originalScoresAsRowPerPerson()
This method returns the original responses entered rearranged as a two dimensional array of doubles orgainized as a row of responses for each person. Missing responses are returned as Double.NaN.

RESPONSES AS USED (RAW DATA)
Responses as used as row per item
public double[][] usedScoresAsRowPerItem()
Usage:                      data = cr.usedScoresAsRowPerItem()
This method returns the raw data responses as used, i.e. minus any deleted items or persons, arranged as a two dimensional array of doubles orgainized as a row of responses for each item. Retained missing responses are returned with the chosen substituted values.

Responses as used as row per person
public double[][] usedScoresAsRowPerItem()
Usage:                      data = cr.usedScoresAsRowPerPerson()
This method returns the raw data responses as used, i.e. minus any deleted items or persons, arranged as a two dimensional array of doubles orgainized as a row of responses for each person. Retained missing responses are returned with the chosen substituted values.

RESPONSES AS USED (STANDARDIZED DATA)
Standardized responses as used as row per item
public double[][] standardizedScoresAsRowPerItem()
Usage:                      data = cr.standardizedScoresAsRowPerItem()
This method returns the standardized data responses as used, i.e. minus any deleted items or persons, arranged as a two dimensional array of doubles orgainized as a row of responses for each item. Retained missing responses are returned with the chosen standardized substituted values.

Standardized responses as used as row per person
public double[][] standardizedScoresAsRowPerItem()
Usage:                      data = cr.standardizedScoresAsRowPerPerson()
This method returns the standardized data responses as used, i.e. minus any deleted items or persons, arranged as a two dimensional array of doubles orgainized as a row of responses for each person. Retained missing responses are returned with the chosen standardized substituted values.

ITEM NAME AND PERSON INDEX OF THE REPLACED RESPONSES
Standardized responses as used as row per item
public String[] indicesOfReplacedScores()
Usage:                      repl = cr.ndicesOfReplacedScores()
This method returns the item name and person index for all 'missing responses' that have been replaced rather than deleted. NOTE that the indices of the persons starts at 1 NOT at 0.

NUMBER OF RESPONSES
Original number of scores
public int originalTotalNumberOfScores()
Usage:                      nScores = cr.originalTotalNumberOfScores()
This method returns the original number of responses entered, i.e. before any deletions.

Number of scores used
public int usedTotalNumberOfScores()
Usage:                      nScores = cr.usedTotalNumberOfScores()
This method returns the number of responses used, i.e. after any deletions.

Number of deleted scores
public int numberOfDeletedScores()
Usage:                      nDeletes = cr.numberOfDeletedScores()
This method returns the number of responses that have been deleted in the handling of any 'missing responses'.

Number of replacement scores
public int numberOfReplacedScores()
Usage:                      nDeletes = cr.numberOfReplacedScores()
This method returns the number of responses that have been replaced in the handling of any 'missing responses'.



SOME OF THE DOCUMENTATION IS STILL UNDER CONSTRUCTION

Some of the item statistic methods, e.g. rawItemStandardDeviation(), person statistic methods, e.g. standardizedPersonVariances(), and allResponses statistic methods, e.g. rawAllResponsesMaximum(), have still to be fully documented. All of these follow the same format as that of the corresponding methods in the
Item Means methods documented above. Their full individual documentation will be added later.



EXAMPLE PROGRAM

An example program, CronbachAnalysis, and the associated documentation may be found on Cronbach Analysis.



OTHER CLASSES USED BY THIS CLASS

This class uses the following classes in this library:


This page was prepared by Dr Michael Thomas Flanagan