CRAN Package Check Results for Package RMAWGEN

Last updated on 2019-12-09 22:51:23 CET.

Flavor Version Tinstall Tcheck Ttotal Status Flags
r-devel-linux-x86_64-debian-clang 1.3.6 7.31 51.00 58.31 ERROR
r-devel-linux-x86_64-debian-gcc 1.3.6 5.51 40.61 46.12 OK
r-devel-linux-x86_64-fedora-clang 1.3.6 69.16 OK
r-devel-linux-x86_64-fedora-gcc 1.3.6 71.14 OK
r-devel-windows-ix86+x86_64 1.3.6 11.00 81.00 92.00 OK
r-devel-windows-ix86+x86_64-gcc8 1.3.6 14.00 67.00 81.00 OK
r-patched-linux-x86_64 1.3.6 6.30 48.36 54.66 OK
r-patched-solaris-x86 1.3.6 92.30 OK
r-release-linux-x86_64 1.3.6 6.53 47.87 54.40 OK
r-release-windows-ix86+x86_64 1.3.6 11.00 64.00 75.00 OK
r-release-osx-x86_64 1.3.6 OK
r-oldrel-windows-ix86+x86_64 1.3.6 7.00 67.00 74.00 OK
r-oldrel-osx-x86_64 1.3.6 OK

Check Details

Version: 1.3.6
Check: examples
Result: ERROR
    Running examples in 'RMAWGEN-Ex.R' failed
    The error most likely occurred in:
    
    > base::assign(".ptime", proc.time(), pos = "CheckExEnv")
    > ### Name: extractmonths
    > ### Title: Extracts the rows of a matrix corresponding to requested months
    > ### of a year given the date (origin) of the first row
    > ### Aliases: extractmonths
    >
    > ### ** Examples
    >
    >
    > extractmonths()
     ----------- FAILURE REPORT --------------
     --- failure: the condition has length > 1 ---
     --- srcref ---
    :
     --- package (from environment) ---
    RMAWGEN
     --- call from context ---
    extractmonths()
     --- call from argument ---
    if (class(data) == "matrix" | class(data) == "data.frame") {
     ndata = nrow(data)
     start <- as.integer(julian(as.POSIXct(origin, tz = "GMT")))
     years <- years(as.chron(as.POSIXct(origin, tz = "GMT") +
     1:ndata - 1))
     if (is.null(year)) {
     out <- (data[which(months_f(1:ndata + start - 1, abbreviate = TRUE) %in%
     when), ])
     }
     else {
     out <- (data[which((months_f(1:ndata + start - 1, abbreviate = TRUE) %in%
     when) & (years %in% year)), ])
     }
    } else {
     ndata = length(data)
     start <- as.integer(julian(as.POSIXct(origin), tz = "GMT"))
     if (is.null(year)) {
     out <- (data[which(months_f(1:ndata + start - 1, abbreviate = TRUE) %in%
     when)])
     }
     else {
     out <- (data[which((months_f(1:ndata + start - 1, abbreviate = TRUE) %in%
     when) & (year %in% years))])
     }
    }
     --- R stacktrace ---
    where 1: extractmonths()
    
     --- value of length: 2 type: logical ---
    [1] TRUE FALSE
     --- function from context ---
    function (data = array(1:ndim_max, dim = c(ndim_max, 1)), ndim_max = 1e+05,
     when = c("Dec", "Jan", "Feb"), year = NULL, origin = "1961-1-1")
    {
     out <- NULL
     if (class(data) == "matrix" | class(data) == "data.frame") {
     ndata = nrow(data)
     start <- as.integer(julian(as.POSIXct(origin, tz = "GMT")))
     years <- years(as.chron(as.POSIXct(origin, tz = "GMT") +
     1:ndata - 1))
     if (is.null(year)) {
     out <- (data[which(months_f(1:ndata + start - 1,
     abbreviate = TRUE) %in% when), ])
     }
     else {
     out <- (data[which((months_f(1:ndata + start - 1,
     abbreviate = TRUE) %in% when) & (years %in% year)),
     ])
     }
     }
     else {
     ndata = length(data)
     start <- as.integer(julian(as.POSIXct(origin), tz = "GMT"))
     if (is.null(year)) {
     out <- (data[which(months_f(1:ndata + start - 1,
     abbreviate = TRUE) %in% when)])
     }
     else {
     out <- (data[which((months_f(1:ndata + start - 1,
     abbreviate = TRUE) %in% when) & (year %in% years))])
     }
     }
     return(out)
    }
    <bytecode: 0x3133628>
    <environment: namespace:RMAWGEN>
     --- function search by body ---
    Function extractmonths in namespace RMAWGEN has this body.
     ----------- END OF FAILURE REPORT --------------
    Error in if (class(data) == "matrix" | class(data) == "data.frame") { :
     the condition has length > 1
    Calls: extractmonths
    Execution halted
Flavor: r-devel-linux-x86_64-debian-clang