Category Archives: R – 6337

Click Here for Code on Performing DIF Analysis

Differential item functioning (DIF) refers to the statistical property of items that have different parameters between two groups after ability has been taken into account. That is, examinees of different groups have differing probabilities of success on an item after … Continue reading

Posted in R - 6337 | Leave a comment

Click Here for Exploratory Factor Analysis Code

This code will walk you through exploratory factor analysis with the dataset posted in Blackboard. I will call it “efa”. The data were collected using a 14-item survey instrument with Likert-type response scales. Thus, we will be factor analyzing the … Continue reading

Posted in R - 6337 | Leave a comment

Click Here for Code to Compute Variance Components for Two Facets (Generalizability Theory)

Posted in R - 6337 | Leave a comment

Click Here for Classical Test Theory Item Analysis

Classical Item Analysis Grant B. Morgan The code below produces classical item analysis and was taken from the IRT website of Dr. Brian Habing at the University of South Carolina (http://www.stat.sc.edu/~habing/courses/778S06.html). The chunk of code below defines the items function. … Continue reading

Posted in R - 6337 | Leave a comment

Click Here for Factor Analysis-based Reliability – Omega

Computing Omega Grant B. Morgan We have talked a bit about the differences between three models based on Classical Test Theory (i.e., parallel, tau equivalent, and congeneric tests). You can take the output from a chosen model to estimate the … Continue reading

Posted in R - 6337 | Leave a comment

Click for Code to Read in the Assignment 2 dataset

Here is a sample of code to read in the data for assignment #2. I posted the datafile on Blackboard so you can downloaded it. You’ll just need to update the code to reflect the location of the file on … Continue reading

Posted in R - 6337 | Leave a comment

Click Here for Classical Test Theory Reliability Functions

Classical Test Theory Reliability Functions The data used to demonstrate these functions is read in first. data_demo <- read.table(“C:\\Users\\grant_morgan\\Desktop\\Teaching\\EDP 6337 – Psychometric Theory\\Spring 2014\\Data\\data_demo.DAT”, sep = “,”, header = FALSE) The code below contains 3 functions that can aid in … Continue reading

Posted in R - 6337, R - 6366 | Leave a comment

Click Here for Code on Reliability Model Comparison Notes

CTT-Based Model Comparisons library(lavaan) ## This is lavaan 0.5-22 ## lavaan is BETA software! Please report any bugs. #Enter a covariance matrix. lower <- ‘ 12 6 9 6 5 12 4 5 7 9 5 4 3 3 9’ … Continue reading

Posted in R - 6337 | Leave a comment

Click Here for Simulating Data for Model Comparisons

Simulating Data for Model Comparisons Simulating Data for Model Comparisons The function that is sourced below was taken from William Revelle's e-book on applications of psychometric theory using R. The full e-book can be found at: http://personality-project.org/r/book/ . To run … Continue reading

Posted in R - 6337 | Leave a comment

Click Here for Reading Data into R

Reading Data into R Grant B. Morgan January 13, 2016 I’ll be the first to admit that reading data into R can be a major pain when you’re first starting out. There are many ways to read data into R … Continue reading

Posted in R - 6337 | Leave a comment