CRAN Package Check Results for Package sambia

Last updated on 2023-03-24 22:00:03 CET.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 0.1.0 11.22 99.17 110.39 ERROR
r-devel-linux-x86_64-debian-gcc 0.1.0 9.54 77.51 87.05 NOTE
r-devel-linux-x86_64-fedora-clang 0.1.0 152.31 NOTE
r-devel-linux-x86_64-fedora-gcc 0.1.0 141.94 NOTE
r-patched-linux-x86_64 0.1.0 8.16 97.57 105.73 NOTE
r-release-linux-x86_64 0.1.0 12.02 96.43 108.45 NOTE
r-release-macos-arm64 0.1.0 38.00 NOTE
r-release-macos-x86_64 0.1.0 73.00 NOTE
r-release-windows-x86_64 0.1.0 18.00 125.00 143.00 NOTE
r-oldrel-macos-arm64 0.1.0 46.00 NOTE
r-oldrel-macos-x86_64 0.1.0 63.00 NOTE
r-oldrel-windows-ix86+x86_64 0.1.0 24.00 153.00 177.00 NOTE

Check Details

Version: 0.1.0
Check: LazyData
Result: NOTE
     'LazyData' is specified without a 'data' directory
Flavors: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-patched-linux-x86_64, r-release-linux-x86_64, r-release-macos-arm64, r-release-macos-x86_64, r-release-windows-x86_64, r-oldrel-macos-arm64, r-oldrel-macos-x86_64, r-oldrel-windows-ix86+x86_64

Version: 0.1.0
Check: examples
Result: ERROR
    Running examples in ‘sambia-Ex.R’ failed
    The error most likely occurred in:
    
    > base::assign(".ptime", proc.time(), pos = "CheckExEnv")
    > ### Name: smoteMod
    > ### Title: smoteMod is a modified version of the 'synthetic minority
    > ### oversampling technique to generate new data.
    > ### Aliases: smoteMod
    >
    > ### ** Examples
    >
    > ## simulate data for a population
    > require(pROC)
    Loading required package: pROC
    Type 'citation("pROC")' for a citation.
    
    Attaching package: ‘pROC’
    
    The following objects are masked from ‘package:stats’:
    
     cov, smooth, var
    
    >
    > set.seed(1342334)
    > N = 100000
    > x1 <- rnorm(N, mean=0, sd=1)
    > x2 <- rt(N, df=25)
    > x3 <- x1 + rnorm(N, mean=0, sd=.6)
    > x4 <- x2 + rnorm(N, mean=0, sd=1.3)
    > x5 <- rbinom(N, 1, prob=.6)
    > x6 <- rnorm(N, 0, sd = 1) # noise not known as variable
    > x7 <- x1*x5 # interaction
    > x <- cbind(x1, x2, x3, x4, x5, x6, x7)
    >
    > ## stratum variable (covariate)
    > xs <- c(rep(1,0.1*N), rep(0,(1-0.1)*N))
    >
    > ## effects
    > beta <- c(-1, 0.2, 0.4, 0.4, 0.5, 0.5, 0.6)
    > beta0 <- -2
    >
    > ## generate binary outcome
    > linpred.slopes <- log(0.5)*xs + c(x %*% beta)
    > eta <- beta0 + linpred.slopes
    >
    > p <- 1/(1+exp(-eta)) # this is the probability P(Y=1|X), we want the binary outcome however:
    > y<-rbinom(n=N, size=1, prob=p) #
    >
    > population <- data.frame(y,xs,x)
    >
    > #### draw "given" data set for training
    > sel.prob <- rep(1,N)
    > sel.prob[population$xs == 1] <- 9
    > sel.prob[population$y == 1] <- 8
    > sel.prob[population$y == 1 & population$xs == 1] <- 150
    > ind <- sample(1:N, 200, prob = sel.prob)
    >
    > data = population[ind, ]
    >
    > ## calculate weights from original numbers for xs and y
    > w.matrix <- table(population$y, population$xs)/table(data$y, data$xs)
    > w <- rep(NA, nrow(data))
    > w[data$y==0 & data$xs ==0] <- w.matrix[1,1]
    > w[data$y==1 & data$xs ==0] <- w.matrix[2,1]
    > w[data$y==0 & data$xs ==1] <- w.matrix[1,2]
    > w[data$y==1 & data$xs ==1] <- w.matrix[2,2]
    >
    > ### draw a test data set
    > newdata = population[sample(1:N, size=200 ), ]
    >
    > K = 5
    > genData = smoteMod(data.x = data[ , -which(colnames(data) %in% c('y', 'xs'))] ,
    + stratum = w, data.y = data$y, weights = w, K=K)
    Error in get.knnx(data, query, k, algorithm) :
     DLL requires the use of native symbols
    Calls: smoteMod -> smoteNew -> <Anonymous> -> <Anonymous> -> get.knnx
    Execution halted
Flavor: r-devel-linux-x86_64-debian-clang