# NOT RUN {
library(dplyr)
db = start_new_project(verbAggrRules, "verbAggression.db")
add_booklet(db, verbAggrData, "aggression")
par = fit_enorm(db)
pv = plausible_values(db, par)
mu = mean(pv$PV1)
sigma = sd(pv$PV1)
# We'll use the behavior an item depicts as a basis for making the clusters,
# thus creating clusters of similar items.
design = data.frame(item_id = verbAggrProperties$item_id,
cluster = verbAggrProperties$behavior)
# specify the actual sample for display in the group_leader page
population = get_testscores(db) %>%
group_by(test_score) %>%
summarise(frequency=n())
db3dc = create3DC('test3DC.db')
add_test3DC(db3dc, parms=par, design, mu=mu, sigma=sigma,
test_id='verbal_aggression', standards='verbally aggressive',
population=population)
#get a preview
plot3DC(db3dc)
dbDisconnect(db3dc)
close_project(db)
# }
# NOT RUN {
# }
Run the code above in your browser using DataLab