anchorpoint: Function to produce anchorpoint objects

Description Usage Arguments Value References Examples

View source: R/anchorpoint.R

Description

Function to conduct the anchor point selection method of Strobl et al. (2021)

Usage

1
2
3
4
5
6
anchorpoint(
  rm1,
  rm2,
  select = c("CLF Criterion", "Gini Index"),
  grid = c("symmetric", "sparse")
)

Arguments

rm1

Fitted Rasch Model object for the first group of test takers

rm2

Fitted Rasch Model object for the second group of test takers

select

a string, specifying the criterion that is evaluated ("CLF Criterion" or "Gini Index", abbreviations are accepted)

grid

a string, specifying the method that is used to generate the grid of possible shifts to be evaluated

Value

an anchorpoint object containing:

References

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
# Load the SPISA data set (general knowledge quiz - more information at ?SPISA)
library("psychotree")
data("SPISA")

# Fit the Rasch Models for the two groups females and males
fit <- anchorpoint::raschFit(SPISA, resp.mat.name='spisa', group.name='gender')

# Rasch Model fit for the first and second group
rm1 <- fit$rm1
rm2 <- fit$rm2

# Fit an Anchorpoint object
ap_object <- anchorpoint(rm1,rm2,select = "Gini Index", grid = "sparse")

# inspect the Anchorpoint object
# The print function summarizes the Global Optimum for the selected methods
print(ap_object)

# The summary function summarizes the Global Optimum for the selected methods
# and shows all the other results
summary(ap_object)

# The plot function shows the criterion plot (criterion value vs. shifts).
plot(ap_object)

# To extract the criterion value and shift for a specific position on the plot,
# set location_picker = TRUE and execute the command.
# Then, click on the desired positions and press ESCAPE.
plot(ap_object, location_picker = TRUE)

lucasmanuelkohler/anchorpoint documentation built on April 16, 2021, 6:41 a.m.