Learn R Programming

SGP (version 1.0-3.0)

createKnotsBoundaries: Function to create Knots and Boundaries from supplied data in LONG format.

Description

The function createKnotsBoundaries creates Knots, Boundaries and Loss/Hoss scores for subsequent use and embedding in SGPstateData.

Usage

createKnotsBoundaries(tmp.data,
	 knot.cut.percentiles=c(0.2,0.4,0.6,0.8))

Arguments

tmp.data
Data supplied to function in LONG format. See sgpData_LONG for exemplar. tmp.data must contain, at least, variables 'VALID_CASE', 'CONTENT_AREA', 'SCALE_SCORE', 'GRADE'
knot.cut.percentiles
A numeric vector of quantiles of 'SCALE_SCORE' to be used as the cut points. Default is to use the 20th, 40th, 60th, and 80th percentiles (i.e., c(0.2,0.4,0.6,0.8)).

Value

  • Returns a list containing Knots, Boundaries and Loss/Hoss scores.

Examples

Run this code
DEMO_Knots_Boundaries <- createKnotsBoundaries(sgpData_LONG)

Run the code above in your browser using DataLab