womRPredVals: Compute predicted values for working memory models in the...

Description Usage Arguments Details Value See Also Examples

View source: R/statFuncs.R

Description

The RPredVals function computes predicted response probabilities for a specified working memory model and design, given values of the effect parameters. This function is useful for model checking.

Usage

1
2
     womRPredVals(x,setup)
     

Arguments

x

the vector containing values at which to evaluate the function.

setup

a list object, created by means of the womExtractModel function, containing the model specification.

Details

The womRPredVals function computes predicted probabilities for the model and design specified by the setup argument. The probability of responding “change” in a change detection task is predicted for each trial.

For further details, see the user's manual at http://wmcapacity.r-forge.r-project.org/.

Value

A vector of predicted probabilities; each element corresponds to a trial.

See Also

wommbatGUI, for fitting the working memory models, and womExtractModel for extracting a model specification.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
     ## Not run: 
     ## load Visual Array data set (Rouder et al., 2008)
     data(VisualArray)

     wommbatGUI(dataFrame = VisualArray)
     
	 ## Once the model is defined via the GUI, 
     ## compute log-likelihood at posterior mean
	 ## replace 'Model' with model name (in quotes)
	 myModel = womExtractModel('Model')
	 posteriorMean = myModel$results$pointEst[,5]
	 
	 womRPredVals(posteriorMean,myModel)
     
## End(Not run)
     
     

WMCapacity documentation built on May 1, 2019, 8:01 p.m.