The R package LW1949 automates the steps taken in Litchfield and Wilcoxon's (1949) manual approach to evaluating dose-effect experiments (Adams et al. 2016). Letting the computer do the work saves time and yields the best fit possible using the Litchfield Wilcoxon approach (by minimizing the chi-squared statistic). You can also try a brief demonstration of LW1949 in this web app.
Install
install.packages("LW1949")
and load the LW1949 package.
library(LW1949)
Use the dataprep
function to create a data frame with the results of a dose-effect experiment. Provide information on three key input variables,
dose
), ntot
), and nfx
).conc <- c(0.0625, 0.125, 0.25, 0.5, 1, 2, 3) numtested <- rep(8, 7) numaffected <- c(1, 4, 4, 7, 8, 8, 8) mydat <- dataprep(dose=conc, ntot=numtested, nfx=numaffected)
The dataprep
function puts the input variables into a data frame along with several new variables,
rec
), pfx
),log10dose
), bitpfx
), fxcateg
) identifying none (0), partial (50), and complete (100) effects, and LWkeep
) to identify observations to keep when applying Litchfield and Wilcoxon's (1949) method (their step A).mydat
Use the fitLWauto
and LWestimate
functions to fit a dose-effect relation following Litchfield and Wilcoxon's (1949) method.
intslope <- fitLWauto(mydat) fLW <- LWestimate(intslope, mydat)
The output from fitLWauto
is a numeric vector of length two, the estimated intercept and slope of the best fitting line on the log10-probit scale..
intslope
The output from LWestimate
is a list with three elements,
chi
, the chi-squared test comparing observed and expected effects, including the expected effects, the "corrected" expected effects (step B in Litchfield and Wilcoxon 1949), and the contribution to the chi-squared statistic (their step C);params
, the estimated intercept and slope on the log10-probit scale; andLWest
, additional estimates calculated in the process of using Litchfield and Wilcoxon's (1949) method (their steps D and E).fLW
Use the predlinear
function and the fitted Litchfield and Wilcoxon model to estimate the effective doses for specified percent effects (with 95% confidence limits).
pctaffected <- c(25, 50, 99.9) predlinear(pctaffected, fLW)
Use the plotDELP
and plotDE
functions to plot the raw data on the log10-probit and arithmetics scales. Observations with no or 100% affected are plotted using white filled circles (at 0.1 and 99.9% respectively in the log10-probit plot).
Use the predLinesLP
and predLines
functions to add the L-W predicted relations to both plots, with 95% horizontal confidence intervals for the predicted dose to elicit a given percent affected.
plotDELP(mydat) predLinesLP(fLW) plotDE(mydat) predLines(fLW)
Adams, J. V., K. S. Slaght, and M. A. Boogaard. 2016. An automated approach to Litchfield and Wilcoxon's evaluation of dose-effect experiments using the R package LW1949. Environmental Toxicology and Chemistry 35(12):3058-3061. DOI 10.1002/etc.3490
Litchfield, J. T. Jr. and F. Wilcoxon. 1949. A simplified method of evaluating dose-effect experiments. Journal of Pharmacology and Experimental Therapeutics 96(2):99-113.
LW1949. An automated approach (R package) to Litchfield and Wilcoxon's (1949) evaluation of dose-effect experiments. Available on Cran, with the latest development version on GitHub.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.