Learn R Programming

ndl (version 0.2.18)

acts2probs: Calculate probability matrix from activation matrix, as well as predicted values

Description

acts2probs takes the activation matrix returned by ndlClassify and calculates the matrix of probabilities for the estimated activation matrix, as well as the predicted values of the response variable.

Usage

acts2probs(acts)

Arguments

acts

A matrix of activations (number of observations by number of levels of the response variable).

Value

A list with the following components:

p

a matrix with the probabilities of the levels of the response variable for each observation.

predicted

a character vector with predicted values.

Details

Probabilities in p are obtained by adding the absolute value of the minimum activation to the activation matrix, and renorming. The selection rule used to produce predicted is to choose for each instance in the data the outcome value that has received the highest probability estimate.

References

Arppe, A. and Baayen, R. H. (in prep.). Statistical classification and principles of human learning.

See Also

See also ndlClassify.

Examples

Run this code
# NOT RUN {
data(think)
think.ndl <- ndlClassify(Lexeme ~ Person + Number + Agent + Register, data=think)
pdata <- acts2probs(think.ndl$activationMatrix)
# }

Run the code above in your browser using DataLab