Description Usage Arguments Details Value Author(s) See Also Examples

Simulate data from the Degree-of-Difference model for a given value of d-prime. The boundary parameters can either be specified by the user, or be chosen automatically so as to 1) maximize the likelihood ratio statistic, 2) ensure responses in each category is equally probable across same-pairs and different-pairs or 3) minimize the standard error of d-prime.

1 2 3 |

`d.prime` |
the value of d-prime. |

`ncat` |
the number of response categories. |

`sample.size` |
the sample size for same-pairs and different-pairs. The sample size can be a scalar number in which case the sample sizes for both same-pairs and different-pairs are taken to equal that number. |

`method.tau` |
the method with which to choose the boundary
parameters. If |

`tau` |
if |

`d.prime0` |
if |

`...` |
passed on to |

In principle both d-prime and all boundary parameters have to be
specified in order to be able to simulate from the DOD model.
However, since it
can be difficult to decide which boundary parameters to use for
simulation, `dodSim`

offers ways to choose these parameters
automatically according to the following three criteria:

- equi.prob
the boundary parameters are chosen such that responses in each category are equally probable across same-pairs and different-pairs.

- LR.max
the boundary parameters are chosen such that the likelihood ratio statistic for the test of d-prime is maximized. This choice maximizes the power of the likelihood ratio test and is in a sense an optimal choice of boundary parameters.

- se.min
the boundary parameters are chosen such that the standard error of d-prime is minimized. This method also maximizes the power of the Wald test of d-prime when the null hypothesis is no-difference (d-prime = 0). This method can be numerical unstable for small and large d-prime values (approximately d.prime < 0.5 and d.prime > 5).

Experience shows that the asymptotic properties of the DOD model are not too sensitive to the choice of boundary parameters: power, standard error of d-prime and confidence intervals seem to be fairly constant irrespectively which of the above three criteria are used to choose the boundary parameters.

A 2-by-`ncat`

matrix of counts with same-pairs in the first
row and different-pairs in the second row. First/last column
corresponds to "same"/"different" on the response scale.

Rune Haubo B Christensen

`dod`

, `dod_fit`

,
`dodControl`

, `optimal_tau`

,
`dodPwr`

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | ```
## Simulate data from the DOD model with the equi.prob method:
set.seed(125)
(Data <- dodSim(d.prime=1, sample.size=100, method.tau="equi.prob"))
## Simulate data that maximizes the likelihood ratio statistic:
set.seed(125)
dodSim(d.prime=1, sample.size=100, method.tau="LR.max")
## Simulate with user-defined values for the boundary parameters:
dodSim(d.prime=1.5, sample.size=c(100, 100),
method.tau="user.defined", tau=1:4)
## Simulate using different sample sizes for same-pairs and
## different-pairs:
dodSim(d.prime=1, ncat=3, sample.size=c(75, 125),
method.tau="se.min")
``` |

sensR documentation built on May 2, 2019, 9:43 a.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.