* using log directory ‘/data/blackswan/ripley/R/packages/tests-devel/WEE.Rcheck’ * using R Under development (unstable) (2023-03-24 r84037) * using platform: x86_64-pc-linux-gnu (64-bit) * R was compiled by gcc (GCC) 11.3.1 20220421 (Red Hat 11.3.1-2) GNU Fortran (GCC) 11.3.1 20220421 (Red Hat 11.3.1-2) * running under: Fedora 34 (Workstation Edition) * using session charset: UTF-8 * checking for file ‘WEE/DESCRIPTION’ ... OK * checking extension type ... Package * this is package ‘WEE’ version ‘1.0’ * checking package namespace information ... OK * checking package dependencies ... OK * checking if this is a source package ... OK * checking if there is a namespace ... OK * checking for executable files ... OK * checking for hidden files and directories ... OK * checking for portable file names ... OK * checking for sufficient/correct file permissions ... OK * checking whether package ‘WEE’ can be installed ... OK * checking package directory ... OK * checking DESCRIPTION meta-information ... OK * checking top-level files ... OK * checking for left-over 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 package can be unloaded cleanly ... OK * checking whether the namespace can be loaded with stated dependencies ... OK * checking whether the namespace can be unloaded cleanly ... OK * checking loading without being on the library search path ... OK * checking 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 ... [10s/10s] OK * checking Rd files ... OK * checking Rd metadata ... OK * checking Rd line widths ... OK * checking Rd cross-references ... OK * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... OK * checking Rd contents ... OK * checking for unstated dependencies in examples ... OK * checking examples ... OK * checking examples with --run-donttest ... ERROR Running examples in ‘WEE-Ex.R’ failed The error most likely occurred in: > ### Name: WEE-package > ### Title: Weighted Estimated Equation (WEE) Approaches in Genetic > ### Case-Control Studies > ### Aliases: WEE-package WEE > ### Keywords: package > > ### ** Examples > > #---------------------- WEE logistic regression ----------------------# > ## Generate simulated data > # set population size as 500000 > n = 500000 > > # set parameters > beta = c(0.2, 0.1) # P(Y|X,Z) > gamma = c(0.3, log(2), log(2)) #P(D|X,Y,Z) > > # generate the genetic variant X > x = rbinom(n,size=2,prob=0.3) > > # generate the standardized continuous covariate Z correlated with X > z = rnorm(n, mean=0.5*x-0.3, sd=1) > > # generate the binary secondary trait Y > py = exp(-1+beta[1]*x+beta[2]*z)/ + (1+exp(-1+beta[1]*x+beta[2]*z)) > y = rbinom(n,1, py) > > # generate the primary disease D > # (alpha changes to make sure the disease prevalence = 0.1 ) > alpha = -2.88 > pd = exp(alpha+x*gamma[1]+y*log(2)+z*log(2))/ + (1+exp(alpha+x*gamma[1]+y*log(2)+z*log(2))) > d = rbinom(n,size=1,prob=pd) > > # form the population dataset > dat = as.data.frame(cbind(d, y, z, x)) > > # generate sample dataset with 200 cases and 200 controls > dat_cases = dat[which(dat$d==1),] > dat_controls= dat[which(dat$d==0),] > dat_cases_sample = dat_cases[sample(sum(dat$d==1), + 200,replace=FALSE),] > dat_controls_sample = dat_controls[sample(sum(dat$d==0), + 200,replace=FALSE),] > > dat_logistic = rbind(dat_cases_sample,dat_controls_sample) > colnames(dat_logistic) = c("D", "y", "z","x") > D = dat_logistic$D # Disease status > pD = sum(dat$d==1)/500000 # Population disease prevalence > > ## WEE logsitic regression > WEE.logistic(y ~ x + z, D, + data = dat_logistic, pD) Call: WEE.logistic(formula = y ~ x + z, D = D, data = dat_logistic, pd_pop = pD) Coefficients: (Intercept) x z -1.1603134 0.3852332 -0.1878349 > ## No test: > WEE.logistic(y ~ x + z, D, + data = dat_logistic, pD, boot = 500) Error in .check_ncores(cores) : 31 simultaneous processes spawned Calls: WEE.logistic ... %dopar% -> -> mclapply -> .check_ncores Execution halted * checking PDF version of manual ... OK * checking for non-standard things in the check directory ... OK * checking for detritus in the temp directory ... OK * checking for new files in some other directories ... OK * DONE Status: 1 ERROR See ‘/data/blackswan/ripley/R/packages/tests-devel/WEE.Rcheck/00check.log’ for details. Command exited with non-zero status 1 Time 1:01.39, 53.82 + 7.12