c5ls {lazy.mdpref} R Documentation

## Thurstone Case V solution to Paired Comparison Data with logistic probability

### Description

Thurstone Case V solution to Paired Comparison Data with logistic probability

### Usage

```c5ls(f, n, ij, sname = NULL, minp = 1e-09, print = 1)
```

### Arguments

 `f` vector of # of times that the left object was preferred. `n` vector of # of trials per pair or scalar . `ij` matrix indicating the stimulus pair: i, j. `sname` a vector consisting of stimulus name When sname is NULL the elements of ij will be used as the names. `minp` minimum value of probability when n=1. `print` = 1 to print result.

### Details

f_ij is the # of times that sutimulus i is preferred over stimulus j out of n_ij comparisons.

f/n will be converted to z by logit function and
z will be converted to the difference of centered scale values x.

### Value

x The scale value
sname Stimulus name
n2o Name conversion table
llh log likelihood
maxag max value of the gradient vector
varx The variance of the scale values
errorvar The variance of the error term associated with x
xs Scale values normalized to have unit variance
errorvars The variance of the error term associated with xs
xls LS scale values
errorvalls The variance of xls
iter # of iterations used.
eps The convergence criterion

### Examples

```set.seed(1701)
x <- c(-.5,0,1)
ij <- matrix(c(2,1, 3,1, 3,2), 3,2, byrow=1)
ijc <- t( apply(4-ij,1, function(x) paste("s",x,sep="")) )
z <- c(x-x, x-x, x-x)
p <- logistic(z)
n <- c(10,10,10)
f <- mapply( function(size,prob){ rbinom(1,size,prob) }, n, p )
res1 <- c5ls( f, n, ij )
res1 <- c5ls( f, n, ijc, sname=c("s33","s22","s11") )
```

[Package lazy.mdpref version 0.1.2 Index]