* using log directory ‘/srv/hornik/tmp/CRAN/CureAuxSP.Rcheck’ * using R Under development (unstable) (2024-02-25 r85985) * using platform: x86_64-pc-linux-gnu * R was compiled by Debian clang version 17.0.6 (5) Debian flang-new version 17.0.6 (5) * running under: Debian GNU/Linux trixie/sid * using session charset: UTF-8 * checking for file ‘CureAuxSP/DESCRIPTION’ ... OK * this is package ‘CureAuxSP’ version ‘0.0.1’ * package encoding: UTF-8 * checking CRAN incoming feasibility ... [3s/3s] NOTE Maintainer: ‘Jie Ding ’ New submission * 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 serialization versions ... OK * checking whether package ‘CureAuxSP’ can be installed ... [3s/3s] OK * checking package directory ... OK * checking for future file timestamps ... OK * checking DESCRIPTION meta-information ... NOTE Author field differs from that derived from Authors@R Author: ‘Jie Ding [aut, cre], Jialiang Li [aut], Mengxiu Zhang [aut], Xiaoguang Wang [aut, cre]’ Authors@R: ‘Jie Ding [aut, cre] (), Jialiang Li [aut] (), Mengxiu Zhang [aut] (), Xiaoguang Wang [aut] ()’ * 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 ... [1s/1s] OK * checking whether the package can be loaded with stated dependencies ... [1s/1s] OK * checking whether the package can be unloaded cleanly ... [1s/1s] OK * checking whether the namespace can be loaded with stated dependencies ... [0s/0s] OK * checking whether the namespace can be unloaded cleanly ... [0s/0s] OK * checking loading without being on the library search path ... [1s/1s] OK * checking use of S3 registration ... OK * checking dependencies in R code ... WARNING '::' or ':::' import not declared from: ‘mvtnorm’ Packages in Depends field not imported from: ‘lars’ ‘survival’ These packages need to be imported from (in the NAMESPACE file) for when this namespace is loaded but not attached. * checking S3 generic/method consistency ... NOTE Mismatches for apparent methods not registered: print: function(x, ...) print.SMC.AuxSP: function(object) See section ‘Registering S3 methods’ in the ‘Writing R Extensions’ manual. * checking replacement functions ... OK * checking foreign function calls ... OK * checking R code for possible problems ... [3s/3s] NOTE SMC.AFT.fit: no visible global function definition for ‘optim’ SMC.AuxSP: no visible global function definition for ‘model.response’ SMC.AuxSP: no visible global function definition for ‘model.frame’ SMC.AuxSP: no visible global function definition for ‘model.matrix’ SMC.AuxSP.fit: no visible global function definition for ‘is’ SMC.AuxSP.fit: no visible binding for global variable ‘sd’ SMC.AuxSP.fit: no visible global function definition for ‘cov’ SMC.AuxSP.fit: no visible global function definition for ‘pchisq’ SMC.AuxSP.fit: no visible global function definition for ‘pnorm’ sdata.SMC: no visible global function definition for ‘runif’ sdata.SMC: no visible global function definition for ‘rbinom’ sdata.SMC: no visible global function definition for ‘uniroot’ sdata.SMC: no visible binding for global variable ‘nu’ sdata.SMC: no visible global function definition for ‘rexp’ Undefined global functions or variables: cov is model.frame model.matrix model.response nu optim pchisq pnorm rbinom rexp runif sd uniroot Consider adding importFrom("methods", "is") importFrom("stats", "cov", "model.frame", "model.matrix", "model.response", "optim", "pchisq", "pnorm", "rbinom", "rexp", "runif", "sd", "uniroot") to your NAMESPACE file (and ensure that your DESCRIPTION Imports field contains 'methods'). * checking Rd files ... [0s/0s] OK * checking Rd metadata ... OK * checking Rd line widths ... NOTE Rd file 'SMC.AuxSP.Rd': \examples lines wider than 100 characters: yobs = ifelse(!is.na(clinical[,'days_to_death']),clinical[,'days_to_death'],clinical[,'days_to_last_followup'])/365, ER = ifelse(clinical[,'breast_carcinoma_estrogen_receptor_status']=='Positive',1,ifelse(clinical[,'breast_carcinoma_estrogen_rece ... [TRUNCATED] Race = ifelse(clinical[,'race_list']=='BLACK OR AFRICAN AMERICAN','black',ifelse(clinical[,'race_list']=='WHITE','white','other')), Gender = ifelse(clinical[,'gender']=='FEMALE','Female',ifelse(clinical[,'gender']=='MALE','Male',NA)), Stage = sapply(clinical[,'stage_event_pathologic_stage'],function(x,pattern='Stage X|Stage IV|Stage [I]*'){ifelse(grepl(pattern,x),r ... [TRUNCATED] These lines will be truncated in the PDF manual. * checking Rd cross-references ... WARNING Missing link or links in Rd file 'SMC.AFT.Stx.Rd': ‘SMC.AFT.fit()’ Missing link or links in Rd file 'SMC.AFT.Sutx.Rd': ‘SMC.AFT.fit()’ Missing link or links in Rd file 'SMC.AFT.rank.Rd': ‘SMC.AFT.fit()’ Missing link or links in Rd file 'SMC.PH.Stx.Rd': ‘SMC.PH.fit()’ Missing link or links in Rd file 'SMC.PH.Sut.Rd': ‘SMC.PH.fit()’ Missing link or links in Rd file 'SMC.PH.Sutx.Rd': ‘SMC.PH.fit()’ See section 'Cross-references' in the 'Writing R Extensions' manual. * checking for missing documentation entries ... OK * checking for code/documentation mismatches ... OK * checking Rd \usage sections ... WARNING Documented arguments not in \usage in Rd file 'SMC.PH.Sutx.Rd': ‘Var’ Functions with \usage entries need to have the appropriate \alias entries, and all their arguments documented. The \usage entries must correspond to syntactically valid R code. See chapter ‘Writing R documentation files’ in the ‘Writing R Extensions’ manual. * checking Rd contents ... OK * checking for unstated dependencies in examples ... WARNING 'library' or 'require' call not declared from: ‘TCGAbiolinks’ * checking examples ... [83s/83s] ERROR Running examples in ‘CureAuxSP-Ex.R’ failed The error most likely occurred in: > base::assign(".ptime", proc.time(), pos = "CheckExEnv") > ### Name: SMC.AuxSP > ### Title: Semi-parametric mixture cure model with auxiliary subgroup > ### survival information > ### Aliases: SMC.AuxSP > > ### ** Examples > > > #--------------------------------------------------------------------# > # illustration via simulated dataset (from PH mixture cure model) #### > #--------------------------------------------------------------------# > > ## library > library(survival) > library(CureAuxSP) > > ## generate both the internal dataset of interest and the external dataset > > # - the internal dataset > set.seed(1) > sdata.internal <- sdata.SMC(n = 300) cure.rate censoring.rate 0.4866667 0.5933333 > head(sdata.internal) yobs delta X1 X2 1 9.274028 0 -0.4689827 1 2 3.862288 0 -0.2557522 0 3 3.733069 0 0.1457067 0 4 3.915764 0 0.8164156 0 5 6.253989 0 -0.5966361 0 6 3.778745 0 0.7967794 1 > > # - the external dataset > set.seed(1) > sdata.external <- sdata.SMC(n = 10000) cure.rate censoring.rate 0.5068 0.6113 > > ## prepare the auxiliary information based on the external dataset > > # - define two functions for subgroup splitting > gfunc.t1 <- function(X,Z=NULL){ + rbind((X[,1] < 0 & X[,2] == 0), (X[,1] >= 0 & X[,2] == 0), + (X[,1] < 0 & X[,2] == 1), (X[,1] >= 0 & X[,2] == 1))} > gfunc.t2 <- function(X,Z=NULL){rbind((X[,2] == 0), (X[,2] == 1))} > > # - calculate subgroup survival rates > sprob.t1 <- Probs.Sub(tstar = 1, sdata = sdata.external, + G = gfunc.t1(X = sdata.external[,-c(1,2)])) > sprob.t2 <- Probs.Sub(tstar = 2, sdata = sdata.external, + G = gfunc.t2(X = sdata.external[,-c(1,2)])) > cat("Information at t* = 1:", sprob.t1, "\nInformation at t* = 2:", sprob.t2) Information at t* = 1: 0.73 0.7 0.88 0.83 Information at t* = 2: 0.62 0.76> > # - prepare the set that collects information about auxiliary data > aux <- list( + time1 = list(tstar = 1, gfunc = gfunc.t1, sprob = c(0.73,0.70,0.88,0.83)), + time2 = list(tstar = 2, gfunc = gfunc.t2, sprob = c(0.62,0.76)-0.20) + ) > > ## fit the model without auxiliary information > set.seed(1) > sol.PHMC <- SMC.AuxSP( + formula = Surv(yobs,delta) ~ X1 + X2, cureform = ~ X1, + sdata = sdata.internal, aux = NULL, latency = "PH" + ) > print.SMC.AuxSP(object = sol.PHMC) PH Mixture Cure Model without Auxiliary Information: - Cure Probability Model Est SE zvalue pvalue Intercept 0.002550101 0.1424502 0.01790171 9.857173e-01 X1 -1.214829035 0.2864443 -4.24106601 2.224607e-05 - Failure Time Distribution Model Est SE zvalue pvalue X1 0.8765172 0.2072169 4.229950 2.337436e-05 X2 -0.9535575 0.2501417 -3.812069 1.378083e-04 > > ## fit the model with auxiliary information > > # - ignore heterogeneity > set.seed(1) > sol.PHMC.Homo <- SMC.AuxSP( + formula = Surv(yobs,delta) ~ X1 + X2, cureform = ~ X1, + sdata = sdata.internal, aux = aux, hetero = FALSE, latency = "PH" + ) Error in loadNamespace(x) : there is no package called ‘mvtnorm’ Calls: SMC.AuxSP ... loadNamespace -> withRestarts -> withOneRestart -> doWithOneRestart Execution halted * checking PDF version of manual ... [3s/3s] OK * checking HTML version of manual ... [0s/0s] OK * checking for non-standard things in the check directory ... OK * checking for detritus in the temp directory ... OK * DONE Status: 1 ERROR, 4 WARNINGs, 5 NOTEs