ggWrightMap: Wright Map using ggplot

Description Usage Arguments Author(s) References See Also Examples

Description

This function allows to generate Wright Map (also called item-person map) using ggplot() function from package ggplot2. Wright Map is used to display histogram of factor scores and the item difficulty parameters estimated by the Rasch IRT model.

Usage

1
ggWrightMap(theta, b, binwidth = 0.5, color = "blue", size = 15)

Arguments

theta

numeric: vector of ability estimates

b

numeric: vector of difficulty estimates

binwidth

numeric: the width of the bins of histogram

color

character: color of histogram

size

text size in pts

Author(s)

Adela Drabinova
Institute of Computer Science, The Czech Academy of Sciences
Faculty of Mathematics and Physics, Charles University
drabinova@cs.cas.cz

Patricia Martinkova
Institute of Computer Science, The Czech Academy of Sciences
martinkova@cs.cas.cz

References

Wright, B. D., & Stone, M. H. (1979). Best test design.

See Also

wrightMap

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
## Not run: 
library(ShinyItemAnalysis)
library(mirt)

data(dataMedical)
data <- dataMedical[, 1:100]

# Model
fit <- mirt(data, model = 1, itemtype = "Rasch")
# factor scores
theta <- as.vector(fscores(fit))
# difficulty estimates
b <- coef(fit, simplify = T)$items[, "d"]

ggWrightMap(theta, b)

## End(Not run)

kitdouble/ShinyIRT documentation built on May 3, 2019, 5:47 p.m.