* using log directory 'd:/Rcompile/CRANpkg/local/2.9/PK.Rcheck' * using R version 2.9.2 Patched (2009-09-02 r49531) * using session charset: ISO8859-1 * checking for file 'PK/DESCRIPTION' ... OK * this is package 'PK' version '1.2-0' * checking package name space information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking whether package 'PK' can be installed ... OK * checking package directory ... OK * checking for portable file names ... OK * checking DESCRIPTION meta-information ... OK * checking top-level files ... OK * checking index information ... OK * checking package subdirectories ... OK * checking R files for non-ASCII characters ... OK * checking R files for syntax errors ... OK * checking whether the package can be loaded ... OK * checking whether the package can be loaded with stated dependencies ... OK * checking whether the name space can be loaded with stated dependencies ... OK * checking for unstated dependencies in R code ... OK * checking S3 generic/method consistency ... OK * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... OK * checking Rd files ... OK * checking Rd files against version 2 parser ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking data for non-ASCII characters ... OK * checking examples ... ERROR Running examples in 'PK-Ex.R' failed. The error most likely occurred in: > ### * all.class > > flush(stderr()); flush(stdout()) > > ### Name: all.class > ### Title: Different generic functions for class PK. > ### Aliases: plot.PK print.PK summary.PK > ### Keywords: classes > > ### ** Examples > > ## serial sampling desing: example from Nedelman et al. (1995) > conc <- c(2790, 3280, 4980, 7550, 5500, 6650, 2250, 3220, 213, 636) > time <- c(1, 1, 2, 2, 4, 4, 8, 8, 24, 24) > > obj <- auc(conc=conc, time=time, method=c("z", "t"), design="ssd") > > print(obj) Estimation for a serial sampling design Estimate SE 95% t-CI AUC to tlast 59886 5752 (33478;86294) Estimate SE 95% z-CI AUC to tlast 59886 5752 (48611;71161) > > summary(obj) Confidence intervals for a serial sampling design Point estimate est se AUC to tlast 59886 5752.5 Confidence Intervals lower upper 95% CI using a t distribution for AUC to tlast 33477.66 86294.34 95% CI using a z distribution for AUC to tlast 48611.31 71160.69 degrees of freedom: 1.874534 > > ## serial sampling design: example from Nedelman et al. (1995) > conc.m <- c(391, 396, 649, 1990, 3290, 3820, 844, 1650, 75.7, 288) > conc.f <- c(353, 384, 625, 1410, 1020, 1500, 933, 1030, 0, 80.5) > time <- c(1, 1, 2, 2, 4, 4, 8, 8, 24, 24) > > res1 <- auc(conc=conc.m, time=time, method=c('t','z'), design='ssd') > res2 <- auc(conc=conc.f, time=time, method=c('t','z'), design='ssd') > > plot(res1, pch=19, ylim=c(0,5000), xlim=c(0,25)) > plot(res2, pch=21, col='red', add=TRUE) > legend(x=25, y=5000, xjust=1, pch=c(19,21), col=c('black','red'), + legend=c('Male', 'Female')) > > ## batch design: example from Jaki and Wolfsegger (2009), > ## originally in Holder et al. (1999) using data for call > data(Rats) > > data1 <- subset(Rats,Rats$dose==100) > data2 <- subset(Rats,Rats$dose==300) > res1 <- auc(data=data1,method='t', design='batch') Error in as.vector(x, mode) : invalid 'mode' argument Calls: auc ... auc.batch -> levels -> as.factor -> factor -> as.vector Execution halted