Hello,
I am trying to submit an R package to CRAN. There are no notes, comments or
errors when checking on my local machine, but I keep getting an error message
when submitting. I am attaching the log file, but basically the error occurs
when running the examples. In particular, it says
Error in loadNamespace(x) : there is no package called 'survey'
However, my package does not use the ‘survey’ package, and when I include this
package to the Imports field in the DESCRIPTION file, it gives the following
NOTE:
checking dependencies in R code ... NOTE
Namespace in Imports field not imported from: ‘survey’
All declared Imports should be used.
How do I resolve this issue?
Best,
Aaron
Flavor: r-devel-linux-x86_64-debian-gcc, r-devel-windows-x86_64
Check: CRAN incoming feasibility, Result: NOTE
Maintainer: 'Aaron Cohen <[email protected]>'
New submission
Possibly misspelled words in DESCRIPTION:
Valliant (14:24, 15:28)
Venables (10:72)
al (14:36, 15:40)
et (14:33, 15:37)
nnet (10:66)
surveynnet (10:18)
Flavor: r-devel-linux-x86_64-debian-gcc, r-devel-windows-x86_64
Check: examples, Result: ERROR
Running examples in 'surveynnet-Ex.R' failed
The error most likely occurred in:
> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: surveynnet
> ### Title: Neural Net for Complex Survey Data
> ### Aliases: surveynnet
>
> ### ** Examples
>
>
> # short example with body fat dataset
> ## Not run:
> ##D y <- body_fat$pct_body_fat
> ##D x <- body_fat[,c("Weight_kg", "Height_cm", "Age")]
> ##D weight <- body_fat$survey_wt
> ##D strat <- body_fat$stratum
> ##D clust <- body_fat$cluster
> ##D y[strat==1] <- y[strat==1] + 30*0.00015*rnorm(sum(strat==1))
> ##D y[strat==2] <- y[strat==2] + 30*0.15*rnorm(sum(strat==2))
> ##D
> ##D myout <- surveynnet(x,y,weight = weight, strat = strat, clust=clust)
> ##D myout
> ## End(Not run)
>
>
> # NHANES example
> # Predicting Diastolic BP from BMI, Systolic BP and Height
> # PLEASE NOTE: for this example, pass "nest=TRUE" into the
> # "..." parameters of the main function `surveynnet`
>
> x <- nhanes.demo[,c("BMXBMI", "BPXSY1", "BMXHT")]
> weight <- nhanes.demo$WTMEC2YR
> strat <- nhanes.demo$SDMVSTRA
> clust <- nhanes.demo$SDMVPSU
> y <- nhanes.demo$BPXDI1
> myout <- surveynnet(x,y,weight = weight, strat = strat, clust=clust,
nest=TRUE)
Error in loadNamespace(x) : there is no package called 'survey'
Calls: surveynnet ... loadNamespace -> withRestarts -> withOneRestart ->
doWithOneRestart
Execution halted
______________________________________________
[email protected] mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel