eval.surp: Values of a Functional Data Object Defining Surprisal Curves.

View source: R/eval.surp.R

eval.surpR Documentation

Values of a Functional Data Object Defining Surprisal Curves.

Description

A surprisal vector of length M is minus the log to a positive integer base M of a set of M multinomial probabilities. Surprisal curves are functions of a one-dimensional index set, such that at any value of the index set the values of the curves are a surprisal vector. See Details below for further explanations.

Usage

eval.surp(evalarg, Sfdobj, nderiv = 0)

Arguments

evalarg

a vector or matrix of argument values at which the functional data object is to be evaluated.

Sfdobj

a functional data object of dimension M-1 to be evaluated.

nderiv

An integer defining a derivatve of Sfdobj in the set c(0,1,2).

Details

A surprisal M-vector is information measured in M-bits. Since a multinomial probability vector must sum to one, it follows that the surprisal vector S must satisfy the constraint log_M(sum(M^(-S)) = 0. That is, surprisal vectors lie within a curved M-1-dimensional manifold.

Surprisal curves are defined by a set of unconstrained M-1 B-spline functional data objects defined over an index set that are transformed into surprisal curves defined over the index set.

Let C be a K by M-1 coefficient matrix defining the B-spline curves, where K is the number of B-spline basis functions.

Let a M by M-1 matrix Z have orthonormal columns. Matrices satisfying these constraints are generated by function zerobasis().

Let N by K matrix be a matrix of B-spline basis values evaluated at N evaluation points using function eval.basis().

Let N by M matrix X = B * C * t(Z).

Then the N by M matrix S of surprisal values is S = -X + outer(log(rowSums(M^X))/log(M),rep(1,M)).

Value

A N by M matrix S of surprisal values at points evalarg, or their first or second derivatives.

Author(s)

Juan Li and James Ramsay

References

Ramsay, J. O., Li J. and Wiberg, M. (2020) Full information optimal scoring. Journal of Educational and Behavioral Statistics, 45, 297-315.

Ramsay, J. O., Li J. and Wiberg, M. (2020) Better rating scale scores with information-based psychometrics. Psych, 2, 347-360.

See Also

smooth.surp

Examples

#  see example in man/smooth.surp.Rd

TestGardener documentation built on Nov. 24, 2023, 5:08 p.m.