data.prep {subscore} | R Documentation |
This function prepares data into a required list format
Description
This function generates a list of data sets using the scored original data set, which can be used as objects in subscore computing functions.
Usage
data.prep(scored.data, subtest.infor, subtest.names = NULL)
Arguments
scored.data |
Original scored data set with rows as individuals and columns as items. |
subtest.infor |
A numerical vector. The first number indicates the number of subtests, followed by numbers of items on each subscale. |
subtest.names |
Names of the subscales AND the entire test. The default is NULL. If not provided, names of "subtest.1", "subtest.2",..., will be assigned. |
Value
A list that contains item responses of all subtests and the entire test. The list is then used by other functions (e.g., CTTsub) in the package to obtain subscores.
Examples
subtest.infor<-c(3,15,15,20)
subtest.names<-c("Algebra","Geometry","Measurement", "Math")
# This math test consists of 3 subtests, which have 15 algebra
# items, 15 geometry items, and 20 measurement items.
test.data<-data.prep(scored.data, subtest.infor, subtest.names)
[Package subscore version 3.3 Index]