Description Details Author(s) References See Also Examples

Provides functions for calculating test statistics, simulating quantiles and simulating p-values of likelihood ratio contrast tests in regression models with a lack of identifiability.

Package: | LRcontrast |

Type: | Package |

Version: | 1.0 |

Date: | 2015-06-21 |

License: | GPL-3 |

The main functions are:

**qLRcontrast**: Simulates quantiles of likelihood ratio contrast tests

**sLRcontrast**: Calculates test statistics of likelihood ratio contrast tests

**pLRcontrast**: Simulates p-values of likelihood ratio contrast tests

Kevin Kokot

Maintainer: Kevin Kokot <[email protected]>

Dette, H., Titoff, S., Volgushev, S. and Bretz, F. (2015), Dose response signal detection under model uncertainty. Biometrics. doi: 10.1111/biom.12357

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 | ```
# Simulate the 90%, 95% and 99% quantiles of the LR contrast tests where the specified
# models are competing against each other.
# The size of each dose group is equal in this case.
qLRcontrast(dose = c(0, 0.05, 0.2, 0.6, 1), probs = c(0.9, 0.95, 0.99), weight
= c(0.2, 0.2, 0.2, 0.2, 0.2), models = c("linear", "emax",
"exponential", "linlog"), nsim = 10)
# Calculate the LR test statistics with the same underlying models.
# In this case the data is generated by the constant model, i.e. the
# null hypothesis of no dose response is true.
resp <- rnorm(n = 50, mean = 0.2)
dose <- c(rep(0, 10), rep(0.05, 10), rep(0.2, 10), rep(0.6, 10), rep(1, 10))
sLRcontrast(dose = dose, resp = resp, models = c("linear", "emax", "exponential", "linlog"))
# Calculate the p-values in this scenario
pLRcontrast(dose = dose, resp = resp, models = c("linear", "emax", "exponential", "linlog"),
nsim = 10)
``` |

LRcontrast documentation built on May 29, 2017, 6:08 p.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.