* using log directory ‘/data/gannet/ripley/R/packages/tests-OpenBLAS/SVMMaj.Rcheck’ * using R Under development (unstable) (2023-08-28 r85029) * using platform: x86_64-pc-linux-gnu * R was compiled by gcc-13 (GCC) 13.2.0 GNU Fortran (GCC) 13.2.0 * running under: Fedora Linux 36 (Workstation Edition) * using session charset: UTF-8 * using option ‘--no-stop-on-test-error’ * checking for file ‘SVMMaj/DESCRIPTION’ ... OK * checking extension type ... Package * this is package ‘SVMMaj’ version ‘0.2.9.1’ * 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 ‘SVMMaj’ can be installed ... [14s/17s] OK * checking package directory ... OK * checking ‘build’ 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 use of S3 registration ... 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 ... [20s/27s] OK * checking Rd files ... NOTE checkRd: (-1) diabetes.Rd:18: Escaped LaTeX specials: \^ * 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 contents of ‘data’ directory ... OK * checking data for non-ASCII characters ... OK * checking LazyData ... OK * checking data for ASCII and uncompressed saves ... OK * checking sizes of PDF files under ‘inst/doc’ ... OK * checking installed files from ‘inst/doc’ ... OK * checking files in ‘vignettes’ ... OK * checking examples ... [18s/17s] OK * checking for unstated dependencies in ‘tests’ ... OK * checking tests ... Running ‘test_all.R’ [22s/20s] [22s/20s] ERROR Running the tests in ‘tests/test_all.R’ failed. Complete output: > library(testthat) > library(SVMMaj) > test_check("SVMMaj") svmmaj> ## using default settings svmmaj> model1 <- svmmaj( svmmaj+ diabetes$X, diabetes$y, hinge = 'quadratic', lambda = 1) svmmaj> summary(model1) Call: svmmaj.default(X = diabetes$X, y = diabetes$y, lambda = 1, hinge = "quadratic") Settings: lambda 1 hinge error quadratic spline basis no type of kernel linear Data: class labels negative positive rank of X 8 number of predictor variables 8 number of objects 768 omitted objects 0 Model: update method svd number of iterations 9 loss value 490.0413 number of support vectors 691 Confusion matrix: Predicted(yhat) Observed (y) negative positive Total negative 446 54 500 positive 115 153 268 Total 561 207 768 Classification Measures: hit rate 0.78 weighted hit rate 0.78 misclassification rate 0.22 weighted missclassification rate 0.22 TP FP Precision negative 0.892 0.108 0.795 positive 0.571 0.429 0.739 svmmaj> weights.obs = list(positive = 2, negative = 1) svmmaj> ## using radial basis kernel svmmaj> library(kernlab) svmmaj> model2 <- svmmaj( svmmaj+ diabetes$X, diabetes$y, hinge = 'quadratic', lambda = 1, svmmaj+ weights.obs = weights.obs, scale = 'interval', svmmaj+ kernel = rbfdot, svmmaj+ kernel.sigma = 1 svmmaj+ ) svmmaj> summary(model2) Call: svmmaj.default(X = diabetes$X, y = diabetes$y, lambda = 1, weights.obs = weights.obs, scale = "interval", kernel = rbfdot, kernel.sigma = 1, hinge = "quadratic") Settings: lambda 1 hinge error quadratic spline basis no type of kernel rbfkernel parameters of kernel degree = 1 offset = 1 scale = 1 sigma = 1 Data: class labels negative positive rank of X 221 number of predictor variables 8 number of objects 768 omitted objects 0 Model: update method Eigen number of iterations 11 loss value 643.2998 number of support vectors 686 Confusion matrix: Predicted(yhat) Observed (y) negative positive Total negative 376 124 500 positive 54 214 268 Total 430 338 768 Classification Measures: hit rate 0.768 weighted hit rate 0.776 misclassification rate 0.232 weighted missclassification rate 0.224 TP FP Precision negative 0.752 0.248 0.874 positive 0.799 0.201 0.633 svmmaj> ## I-spline basis svmmaj> library(ggplot2) svmmaj> model3 <- svmmaj( svmmaj+ diabetes$X, diabetes$y, weight.obs = weight.obs, svmmaj+ spline.knots = 3, spline.degree = 2 svmmaj+ ) svmmaj> plotWeights(model3, plotdim = c(2, 4)) TableGrob (3 x 3) "arrange": 9 grobs z cells name grob 1 1 (1-1,1-1) arrange gtable[layout] 2 2 (1-1,2-2) arrange gtable[layout] 3 3 (1-1,3-3) arrange gtable[layout] 4 4 (2-2,1-1) arrange gtable[layout] 5 5 (2-2,2-2) arrange gtable[layout] 6 6 (2-2,3-3) arrange gtable[layout] 7 7 (3-3,1-1) arrange gtable[layout] 8 8 (3-3,2-2) arrange gtable[layout] 9 9 (3-3,3-3) arrange gtable[guide-box] Number of observations: 200 Varying parameters : 1 Number of gridpoints : 3 Start cross validation ... group 0 of 5 : *** group 1 of 5 : *** group 2 of 5 : *** group 3 of 5 : *** group 4 of 5 : *** group 5 of 5 : *** Getting optimal parameters ... Done Number of observations: 200 Varying parameters : 2 Number of gridpoints : 15 Start cross validation ... Getting optimal parameters ... Done [ FAIL 1 | WARN 2 | SKIP 3 | PASS 14 ] ══ Skipped tests (3) ═══════════════════════════════════════════════════════════ • empty test (3): 'test_svmmaj.R:59:1', 'test_svmmajcrossval.R:12:1', 'test_svmmajcrossval.R:22:1' ══ Failed tests ════════════════════════════════════════════════════════════════ ── Error ('test_svmmaj.R:134:5'): Test for case when test set lies outside of training set ── Error in `svmmaj.default(X, y)`: Number of classes must be equal to 2 Backtrace: ▆ 1. ├─SVMMaj::svmmaj(X, y) at test_svmmaj.R:134:4 2. └─SVMMaj:::svmmaj.default(X, y) [ FAIL 1 | WARN 2 | SKIP 3 | PASS 14 ] Error: Test failures Execution halted * checking for unstated dependencies in vignettes ... OK * checking package vignettes in ‘inst/doc’ ... OK * checking re-building of vignette outputs ... [236s/187s] OK * checking PDF version of manual ... [10s/14s] OK * checking HTML version of manual ... OK * checking for non-standard things in the check directory ... OK * checking for detritus in the temp directory ... OK * DONE Status: 1 ERROR, 1 NOTE See ‘/data/gannet/ripley/R/packages/tests-OpenBLAS/SVMMaj.Rcheck/00check.log’ for details. Command exited with non-zero status 1 Time 6:08.33, 364.50 + 21.43