r-gregmisc-users Mailing List for R gregmisc package (Page 3)
Brought to you by:
warnes
You can subscribe to this list here.
2006 |
Jan
|
Feb
|
Mar
(12) |
Apr
(5) |
May
(3) |
Jun
(5) |
Jul
(2) |
Aug
(5) |
Sep
(7) |
Oct
(15) |
Nov
(34) |
Dec
(3) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2007 |
Jan
(3) |
Feb
(16) |
Mar
(28) |
Apr
(5) |
May
|
Jun
(5) |
Jul
(9) |
Aug
(50) |
Sep
(29) |
Oct
(9) |
Nov
(25) |
Dec
(7) |
2008 |
Jan
(6) |
Feb
(4) |
Mar
(5) |
Apr
(8) |
May
(26) |
Jun
(11) |
Jul
|
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
(9) |
2009 |
Jan
|
Feb
(1) |
Mar
|
Apr
(2) |
May
(26) |
Jun
|
Jul
(10) |
Aug
(6) |
Sep
|
Oct
(7) |
Nov
(3) |
Dec
(2) |
2010 |
Jan
(45) |
Feb
(11) |
Mar
|
Apr
(1) |
May
(8) |
Jun
(7) |
Jul
(3) |
Aug
(1) |
Sep
|
Oct
(1) |
Nov
(9) |
Dec
(1) |
2011 |
Jan
(2) |
Feb
|
Mar
|
Apr
(3) |
May
(1) |
Jun
|
Jul
|
Aug
(14) |
Sep
(29) |
Oct
(3) |
Nov
|
Dec
(3) |
2012 |
Jan
|
Feb
|
Mar
|
Apr
(7) |
May
(6) |
Jun
(59) |
Jul
|
Aug
(8) |
Sep
(21) |
Oct
|
Nov
|
Dec
|
2013 |
Jan
(1) |
Feb
|
Mar
(10) |
Apr
|
May
(18) |
Jun
(25) |
Jul
(18) |
Aug
(1) |
Sep
(6) |
Oct
(28) |
Nov
(4) |
Dec
(13) |
2014 |
Jan
(7) |
Feb
(5) |
Mar
(4) |
Apr
(36) |
May
(3) |
Jun
(7) |
Jul
(46) |
Aug
(14) |
Sep
(12) |
Oct
(2) |
Nov
|
Dec
(12) |
2015 |
Jan
(4) |
Feb
|
Mar
|
Apr
(80) |
May
(36) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: <wa...@us...> - 2015-04-28 04:45:15
|
Revision: 1979 http://sourceforge.net/p/r-gregmisc/code/1979 Author: warnes Date: 2015-04-28 04:45:14 +0000 (Tue, 28 Apr 2015) Log Message: ----------- Update version requirement for R (>= 2.3.0) and perl (5.10.0). Modified Paths: -------------- trunk/gdata/DESCRIPTION Modified: trunk/gdata/DESCRIPTION =================================================================== --- trunk/gdata/DESCRIPTION 2015-04-28 04:44:08 UTC (rev 1978) +++ trunk/gdata/DESCRIPTION 2015-04-28 04:45:14 UTC (rev 1979) @@ -20,8 +20,8 @@ - value of last evaluated expression ('ans'), and - wrapper for 'sample' that ensures consistent behavior for both scalar and vector arguments ('resample'). -Depends: R (>= 2.13.0) -SystemRequirements: perl +Depends: R (>= 2.3.0) +SystemRequirements: perl (>= 5.10.0) Imports: gtools Version: 2.16.0 Date: 2015-04-25 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-28 04:44:11
|
Revision: 1978 http://sourceforge.net/p/r-gregmisc/code/1978 Author: warnes Date: 2015-04-28 04:44:08 +0000 (Tue, 28 Apr 2015) Log Message: ----------- - first() and last() are now simply wrappers to utils::head() and utils::tail() with a default 'n=1' instead of 'n=6'. - Move code for left() and right() into a separate file. Modified Paths: -------------- trunk/gdata/R/first.R trunk/gdata/man/first.Rd Added Paths: ----------- trunk/gdata/R/left.R Modified: trunk/gdata/R/first.R =================================================================== --- trunk/gdata/R/first.R 2015-04-28 04:41:39 UTC (rev 1977) +++ trunk/gdata/R/first.R 2015-04-28 04:44:08 UTC (rev 1978) @@ -1,30 +1,3 @@ -first <- function(x) UseMethod("first") -last <- function(x) UseMethod("last") - -left <- function(x, n=6) UseMethod("left") -right <- function(x, n=6) UseMethod("left") - - -first.default <- function(x) x[1] -last.default <- function(x) x[length(x)] - - -first.list <- function(x) x[[1]] -last.list <- function(x) x[[length(x)]] - - -left.data.frame <- function(x, n=6) -{ - n <- min(n, ncol(x)) - x[, 1:n] -} -left.matrix <- left.data.frame - - -right.data.frame <- function(x, n=6) -{ - n <- min(n, ncol(x)) - x[, (ncol(x)-n+1):ncol(x)] -} -right.matrix <- right.data.frame - +# Simply call 'first' or 'last' with a different default value for 'n'. +first <- function(x, n=1, ...) head(x, n=n, ...) +last <- function(x, n=1, ...) tail(x, n=n, ...) Added: trunk/gdata/R/left.R =================================================================== --- trunk/gdata/R/left.R (rev 0) +++ trunk/gdata/R/left.R 2015-04-28 04:44:08 UTC (rev 1978) @@ -0,0 +1,38 @@ +left <- function(x, n=6L) UseMethod("left") +right <- function(x, n=6L) UseMethod("left") + +left.data.frame <- function(x, n=6) +{ + stopifnot(length(n) == 1L) + n <- if (n < 0L) + max(ncol(x) + n, 0L) + else min(n, ncol(x)) + x[, seq_len(n), drop = FALSE] +} +left.matrix <- left.data.frame + + +right.data.frame <- function (x, n = 6L, ...) +{ + stopifnot(length(n) == 1L) + ncx <- ncol(x) + n <- if (n < 0L) + max(ncx + n, 0L) + else min(n, ncx) + x[, seq.int(to = ncx, length.out = n), drop = FALSE] +} + +right.matrix <- function (x, n = 6L, addcolnums = TRUE, ...) +{ + stopifnot(length(n) == 1L) + ncx <- ncol(x) + n <- if (n < 0L) + max(ncx + n, 0L) + else min(n, ncx) + sel <- seq.int(to = ncx, length.out = n) + ans <- x[, sel, drop = FALSE] + if (addcolnums && is.null(colnames(x))) + colnames(ans) <- paste0("[", sel, ",]") + ans +} + Modified: trunk/gdata/man/first.Rd =================================================================== --- trunk/gdata/man/first.Rd 2015-04-28 04:41:39 UTC (rev 1977) +++ trunk/gdata/man/first.Rd 2015-04-28 04:44:08 UTC (rev 1978) @@ -1,28 +1,25 @@ \name{first} \alias{first} -\alias{first.default} -\alias{first.list} \alias{last} -\alias{last.default} -\alias{last.list} -\title{Return first or last element of a vector or list} +\title{Return first or last element of an object} \description{ - Return first or last element of a vector or list -} + Return first or last element of an object. These functions are convenience + wrappers for \code{head(x, n=1, ...)} and \code{tail(x, n=1, ...)}. + } \usage{ -first(x) -last(x) -\method{first}{default}(x) -\method{last}{default}(x) -\method{first}{list}(x) -\method{last}{list}(x) +first(x, n=1, ...) +last(x, n=1, ...) } -%- maybe also 'usage' for other objects documented here. \arguments{ - \item{x}{vector or list} + \item{x}{data object} + \item{n}{a single integer. If positive, size for the resulting object: + number of elements for a vector (including lists), rows for a + matrix or data frame or lines for a function. If negative, + all but the ‘n’ last/first number of elements of ‘x’.} + \item{...}{arguments to be passed to or from other methods.} } \value{ - The first or last element of \code{x}. + An object (usually) like ‘x’ but generally smaller. } \author{ Gregory R. Warnes \email{gr...@wa...} @@ -43,5 +40,16 @@ l <- list(a=1, b=2, c=3) first(l) last(l) + +## and data.frames +df <- data.frame(a=1:2, b=3:4, c=5:6) +first(df) +last(df) + +## and matrixes +m <- as.matrix(df) +first(m) +last(m) + } \keyword{ manip } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-28 04:41:42
|
Revision: 1977 http://sourceforge.net/p/r-gregmisc/code/1977 Author: warnes Date: 2015-04-28 04:41:39 +0000 (Tue, 28 Apr 2015) Log Message: ----------- If arguments 'X' or 'FUN' is supplied to reorder.factor(), mimic the behavior of stats::reorder.default() rather than trying to call it via NextMethod. Modified Paths: -------------- trunk/gdata/R/reorder.R trunk/gdata/man/reorder.Rd Modified: trunk/gdata/R/reorder.R =================================================================== --- trunk/gdata/R/reorder.R 2015-04-28 04:27:04 UTC (rev 1976) +++ trunk/gdata/R/reorder.R 2015-04-28 04:41:39 UTC (rev 1977) @@ -1,7 +1,3 @@ -# $Id$ - -# Reorder the levels of a factor. - reorder.factor <- function(x, X, FUN, @@ -13,17 +9,28 @@ constructor <- if (order) ordered else factor if(!missing(X) || !missing(FUN)) - return( NextMethod(x)) + { + if(missing(FUN)) FUN <- 'mean' - if (!missing(new.order)) + ## I would prefer to call stats::reorder.default directly, + ## but it exported from stats, so the relevant code is + ## replicated here: + ## --> + scores <- tapply(X = X, INDEX = x, FUN = FUN, ...) + ans <- (if (order) + ordered + else factor)(x, levels = names(sort(scores, na.last = TRUE))) + attr(ans, "scores") <- scores + ## <-- + return(ans) + } + else if (!missing(new.order)) { if (is.numeric(new.order)) new.order <- levels(x)[new.order] else new.order <- new.order } - else if (!missing(FUN)) - new.order <- names(sort(tapply(X, x, FUN, ...))) else new.order <- sort(levels(x)) Modified: trunk/gdata/man/reorder.Rd =================================================================== --- trunk/gdata/man/reorder.Rd 2015-04-28 04:27:04 UTC (rev 1976) +++ trunk/gdata/man/reorder.Rd 2015-04-28 04:41:39 UTC (rev 1977) @@ -38,23 +38,23 @@ The groups are then sorted by this value, and the resulting order is used for the new factor level names. - If \code{new.order} is provided: For a numeric vector, the new factor - level names are constructed by reordering the factor levels according - to the numeric values. For vectors, \code{new.order} gives the list of - new factor level names. In either case levels omitted from - \code{new.order} will become missing (\code{NA}) values. + If \code{new.order} is a numeric vector, the new factor level names + are constructed by reordering the factor levels according to the + numeric values. If \code{new.order} is a chraccter vector, + \code{new.order} gives the list of new factor level names. In either + case levels omitted from \code{new.order} will become missing + (\code{NA}) values. - If \code{sort} is provided (as it is by default): The new - factor level names are generated by applying the supplied function - to the existing factor level names. With \code{sort=mixedsort} the - factor levels are sorted so that combined numeric and character - strings are sorted in according to character rules on the character - sections (including ignoring case), and the numeric rules for the - numeric sections. See \code{\link[gtools]{mixedsort}} for details. + If \code{sort} is provided (as it is by default): The new factor level + names are generated by calling the function specified by \code{sort} + to the existing factor level \emph{names}. With \code{sort=mixedsort} + (the default) the factor levels are sorted so that combined numeric + and character strings are sorted in according to character rules on + the character sections (including ignoring case), and the numeric + rules for the numeric sections. See \code{\link[gtools]{mixedsort}} + for details. } -\value{ - A new factor with reordered levels -} +\value{ A new factor with reordered levels } \author{Gregory R. Warnes \email{gr...@wa...}} @@ -67,21 +67,21 @@ summary(trt) # Note that the levels are not in a meaningful order. - # Change the order to something useful - # default "mixedsort" ordering + # Change the order to something useful.. + # - default "mixedsort" ordering trt2 <- reorder(trt) summary(trt2) - # using indexes: + # - using indexes: trt3 <- reorder(trt, new.order=c(4, 2, 3, 1)) summary(trt3) - # using label names: + # - using label names: trt4 <- reorder(trt, new.order=c("PLACEBO", "300 MG", "600 MG", "1200 MG")) summary(trt4) - # using frequency + # - using frequency trt5 <- reorder(trt, X=as.numeric(trt), FUN=length) summary(trt5) - # drop out the '300 MG' level + # Drop out the '300 MG' level trt6 <- reorder(trt, new.order=c("PLACEBO", "600 MG", "1200 MG")) summary(trt6) } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-28 04:27:06
|
Revision: 1976 http://sourceforge.net/p/r-gregmisc/code/1976 Author: warnes Date: 2015-04-28 04:27:04 +0000 (Tue, 28 Apr 2015) Log Message: ----------- Changes to mixedsort(): - Hands off objects that are not character vectors to the default sort. - Add 'decreasing', 'na.last', and 'blank.last' arguments. Modified Paths: -------------- trunk/gtools/R/mixedsort.R trunk/gtools/man/mixedsort.Rd Modified: trunk/gtools/R/mixedsort.R =================================================================== --- trunk/gtools/R/mixedsort.R 2015-04-28 04:16:56 UTC (rev 1975) +++ trunk/gtools/R/mixedsort.R 2015-04-28 04:27:04 UTC (rev 1976) @@ -1,8 +1,6 @@ -# $Id$ - mixedsort <- function(x, decreasing=FALSE, na.last=TRUE, blank.last=FALSE) { - ord <- mixedorder(x, decreasing=decreasing, na.last=na.last, + svn ord <- mixedorder(x, decreasing=decreasing, na.last=na.last, blank.last=blank.last) x[ord] } @@ -116,5 +114,3 @@ return(retval) } - - Modified: trunk/gtools/man/mixedsort.Rd =================================================================== --- trunk/gtools/man/mixedsort.Rd 2015-04-28 04:16:56 UTC (rev 1975) +++ trunk/gtools/man/mixedsort.Rd 2015-04-28 04:27:04 UTC (rev 1976) @@ -1,5 +1,3 @@ -% $Id$ -% \name{mixedsort} \alias{mixedsort} \alias{mixedorder} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-28 04:16:59
|
Revision: 1975 http://sourceforge.net/p/r-gregmisc/code/1975 Author: warnes Date: 2015-04-28 04:16:56 +0000 (Tue, 28 Apr 2015) Log Message: ----------- Add private function 'checkReverseDependencies'. Modified Paths: -------------- trunk/gtools/DESCRIPTION trunk/gtools/R/mixedsort.R trunk/gtools/man/mixedsort.Rd Added Paths: ----------- trunk/gtools/R/checkReverseDependencies.R trunk/gtools/R/roman2int.R trunk/gtools/R/trim.R trunk/gtools/R/unByteCode.R trunk/gtools/src/roman2int.c Removed Paths: ------------- trunk/gtools/inst/ChangeLog Modified: trunk/gtools/DESCRIPTION =================================================================== --- trunk/gtools/DESCRIPTION 2015-04-25 17:16:31 UTC (rev 1974) +++ trunk/gtools/DESCRIPTION 2015-04-28 04:16:56 UTC (rev 1975) @@ -1,26 +1,26 @@ Package: gtools Title: Various R Programming Tools Description: Functions to assist in R programming, including: - - assist in developing, updating, and maintaining R and R packages ('ask', 'checkRVersion', - 'getDependencies', 'keywords', 'scat'), + - assist in developing, updating, and maintaining R and R packages ('ask', 'checkRVersion', + 'getDependencies', 'keywords', 'scat'), - calculate the logit and inverse logit transformations ('logit', 'inv.logit'), - test if a value is missing, empty or contains only NA and NULL values ('invalid'), - manipulate R's .Last function ('addLast'), - define macros ('defmacro'), - detect odd and even integers ('odd', 'even'), - - convert strings containing non-ASCII characters (like single quotes) to plain ASCII ('ASCIIfy'), + - convert strings containing non-ASCII characters (like single quotes) to plain ASCII ('ASCIIfy'), - perform a binary search ('binsearch'), - sort strings containing both numeric and character components ('mixedsort'), - create a factor variable from the quantiles of a continuous variable ('quantcut'), - enumerate permutations and combinations ('combinations', 'permutation'), - - calculate and convert between fold-change and log-ratio ('foldchange', + - calculate and convert between fold-change and log-ratio ('foldchange', 'logratio2foldchange', 'foldchange2logratio'), - - calculate probabilities and generate random numbers from Dirichlet distributions + - calculate probabilities and generate random numbers from Dirichlet distributions ('rdirichlet', 'ddirichlet'), - apply a function over adjacent subsets of a vector ('running'), - - Modify the TCP\_NODELAY ('de-Nagle') flag for socket objects, - - Efficient 'rbind' of data frames, even if the column names don't match ('smartbind'), - - Generate significance stars from p-values ('stars.pval'). + - modify the TCP\_NODELAY ('de-Nagle') flag for socket objects, + - efficient 'rbind' of data frames, even if the column names don't match ('smartbind'), + - generate significance stars from p-values ('stars.pval'). Version: 3.4.3 Date: 2015-04-23 Author: Gregory R. Warnes, Ben Bolker, and Thomas Lumley Added: trunk/gtools/R/checkReverseDependencies.R =================================================================== --- trunk/gtools/R/checkReverseDependencies.R (rev 0) +++ trunk/gtools/R/checkReverseDependencies.R 2015-04-28 04:16:56 UTC (rev 1975) @@ -0,0 +1,22 @@ +packagefile="gdata_2.16.0.tar.gz" +destdir=tempdir() + +checkReverseDependencies <- function(packagefile, destdir=tempdir(), cleanup=FALSE ) + { + if(!file.exists(packagefile)) + stop(packagefile, " does not exist!") + + cat("Using directory '", destdir, "'. Remember to delete it when done.\n", sep='') + + file.copy(packagefile, destdir) + + package <- gsub("_.*$", "", packagefile) + + rdeps <- tools::package_dependencies(package, db=available.packages(), reverse = TRUE)[[1]] + cat( length(rdeps), "reverse dependencies:\n") + print(rdeps) + + tools::check_packages_in_dir(destdir, reverse=list(), Ncpus=6) + + if(cleanup) unlink(destdir, recursive=TRUE, force=TRUE) + } Modified: trunk/gtools/R/mixedsort.R =================================================================== --- trunk/gtools/R/mixedsort.R 2015-04-25 17:16:31 UTC (rev 1974) +++ trunk/gtools/R/mixedsort.R 2015-04-28 04:16:56 UTC (rev 1975) @@ -1,8 +1,13 @@ # $Id$ -mixedsort <- function(x) x[mixedorder(x)] +mixedsort <- function(x, decreasing=FALSE, na.last=TRUE, blank.last=FALSE) + { + ord <- mixedorder(x, decreasing=decreasing, na.last=na.last, + blank.last=blank.last) + x[ord] + } -mixedorder <- function(x) +mixedorder <- function(x, decreasing=FALSE, na.last=TRUE, blank.last=FALSE) { # - Split each each character string into an vector of strings and # numbers @@ -14,10 +19,9 @@ else if(length(x)==1) return(1) - if( is.numeric(x) ) - return( order(x) ) + if( !is.character(x) ) + return( order(x, decreasing=decreasing, na.last=na.last) ) - delim="\\$\\@\\$" numeric <- function(x) @@ -35,12 +39,6 @@ which.nas <- which(is.na(x)) which.blanks <- which(x=="") - if(length(which.blanks) >0) - x[ which.blanks ] <- -Inf - - if(length(which.nas) >0) - x[ which.nas ] <- Inf - #### # - Convert each character string into an vector containing single # character and numeric values. @@ -79,7 +77,7 @@ ) # now order them - rank.numeric <- sapply(step1.numeric.t,rank) + rank.numeric <- sapply(step1.numeric.t, rank) rank.character <- sapply(step1.character.t, function(x) as.numeric(factor(x))) @@ -95,9 +93,27 @@ order.frame <- as.data.frame(rank.overall) if(length(which.nas) > 0) - order.frame[which.nas,] <- Inf - retval <- do.call("order",order.frame) + if(is.na(na.last)) + order.frame[which.nas,] <- NA + else if(na.last) + order.frame[which.nas,] <- Inf + else + order.frame[which.nas,] <- -Inf + if(length(which.blanks) > 0) + if(is.na(blank.last)) + order.frame[which.blanks,] <- NA + else if(blank.last) + order.frame[which.blanks,] <- 1e99 + else + order.frame[which.blanks,] <- -1e99 + + order.frame <- as.list(order.frame) + order.frame$decreasing <- decreasing + order.frame$na.last <- NA + + retval <- do.call("order", order.frame) + return(retval) } Added: trunk/gtools/R/roman2int.R =================================================================== --- trunk/gtools/R/roman2int.R (rev 0) +++ trunk/gtools/R/roman2int.R 2015-04-28 04:16:56 UTC (rev 1975) @@ -0,0 +1,37 @@ +testConvert <- function() + { + roman <- 'IVXLCDM' + retval <- romandigit.convert(roman) + stopifnot(retval==c(1,5,10,50,100,500,1000)) + return(TRUE) + } + +romandigit.convert <- function(roman) + { + retval <- .C('convert', + roman=as.character(roman), + nchar=as.integer(nchar(roman)), + values=integer(nchar(roman)) + ) + retval$values + } + +roman2int.inner <- function(roman) + { + results <- .C("roman2int", + roman = as.character(roman), + nchar = as.integer(nchar(roman)), + value = integer(1), + + PACKAGE="gtools") + + return(results$value) + } + +roman2int <- function(roman) + { + roman <- trim(toupper(as.character(roman))) + retval <- sapply(roman, roman2int.inner) + retval + } + Added: trunk/gtools/R/trim.R =================================================================== --- trunk/gtools/R/trim.R (rev 0) +++ trunk/gtools/R/trim.R 2015-04-28 04:16:56 UTC (rev 1975) @@ -0,0 +1 @@ +link ../../gdata/R/trim.R \ No newline at end of file Property changes on: trunk/gtools/R/trim.R ___________________________________________________________________ Added: svn:special ## -0,0 +1 ## +* \ No newline at end of property Added: trunk/gtools/R/unByteCode.R =================================================================== --- trunk/gtools/R/unByteCode.R (rev 0) +++ trunk/gtools/R/unByteCode.R 2015-04-28 04:16:56 UTC (rev 1975) @@ -0,0 +1,29 @@ +## Convert a byte-compiled function to an interpreted-code function +unByteCode <- function(fun) +{ + FUN <- eval(parse(text=deparse(fun))) + environment(FUN) <- environment(fun) + FUN +} + +## Replace function definition inside of a locked environment **HACK** +assignEdgewise <- function(name, env, value) +{ + unlockBinding(name, env=env) + assign( name, envir=env, value=value) + lockBinding(name, env=env) + invisible(value) +} + +## Replace byte-compiled function in a locked environment with an +## interpreted-code function +unByteCodeAssign <- function(fun) +{ + name <- gsub('^.*::+','', deparse(substitute(fun))) + FUN <- unByteCode(fun) + retval <- assignEdgewise(name=name, + env=environment(FUN), + value=FUN + ) + invisible(retval) +} Deleted: trunk/gtools/inst/ChangeLog =================================================================== --- trunk/gtools/inst/ChangeLog 2015-04-25 17:16:31 UTC (rev 1974) +++ trunk/gtools/inst/ChangeLog 2015-04-28 04:16:56 UTC (rev 1975) @@ -1,876 +0,0 @@ -2015-04-23 warnes - - * [r1949] R/quantcut.R, man/quantcut.Rd: - The 'q' argument to - quantcut()'s 'q' now accept an integer - indicating the number of equally spaced quantile groups to - create. (Suggestion and patch submitted by Ryan C. Thompson.) - * [r1946] DESCRIPTION: Revers accidental text deletion: - * [r1945] DESCRIPTION, inst/ChangeLog, inst/NEWS: Update for gtools - 3.4.3 - * [r1944] R/smartbind.R, R/strmacro.R: Remove debugging code and - stray browser() call - -2015-04-14 warnes - - * [r1923] DESCRIPTION: Fix typo - -2015-04-09 warnes - - * [r1921] inst/ChangeLog: Update gtools ChangeLog - * [r1920] DESCRIPTION, NAMESPACE, R/loadedPackages.R, - R/na.replace.R, inst/ChangeLog, inst/NEWS, man/loadedPackages.Rd, - man/na.replace.Rd: Move first()/last()/left()/right() to gdata. - Add new functions na.replace() and loadedPackages(). - Add more text to package description. - -2015-04-08 warnes - - * [r1919] NAMESPACE, R/first.R, man/first.Rd, man/left.Rd: Move - first/last/left/right to from gtools to gdata - -2015-04-06 warnes - - * [r1918] man/dirichlet.Rd: Correct URL - * [r1917] inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog for - gtools 3.5.0 - * [r1916] inst/ChangeLog: Add ChangeLog files to repository - * [r1915] R/keywords.R: Implement fix to keywords() needed for - R-3.4.1, as suggested by Kurt - Hornik. - * [r1914] NAMESPACE, R/first.R: - Export S3 methods for first(), - last(), left() and right(). - - Ensure code matches man page for first(), last(), left(), and - right(). - -2014-10-09 warnes - - * [r1897] DESCRIPTION, inst/NEWS: Update for 3.5.0 release of - gtools - * [r1896] R/first.R: Make right() and left() S3 methods for classes - data.frame and matrix - -2014-08-27 warnes - - * [r1872] man/first.Rd: Fix man page - * [r1871] DESCRIPTION, NAMESPACE, R/first.R, man/first.Rd, - man/left.Rd: Finish adding first(), last(), left(), and right(). - * [r1870] R/first.R: Add functions first(), last(), left(), and - right(). - -2014-05-28 warnes - - * [r1816] DESCRIPTION, inst/NEWS: Update for gtools 3.4.1 - * [r1815] tests/smartbind_Dates.R: Add test to ensure smartbind() - properly handles Date columns. - * [r1814] R/smartbind.R: smartbind: Convert non-native type columns - (except factor) to character. - -2014-04-18 arnima - - * [r1813] R/ASCIIfy.R, man/ASCIIfy.Rd: Main arg is 'x' like - showNonASCII(x), preformatted notes instead of verb - -2014-04-17 warnes - - * [r1810] man/ASCIIfy.Rd: Update ASCIIfy man page to match source - code and add keywords - * [r1809] inst/NEWS: Update NEWS for gtools 3.4.0 - * [r1808] DESCRIPTION, NAMESPACE, R/ASCIIfy.R, man/ASCIIfy.Rd: Add - ASCIIfy function posted to RDevel by Arni Magnusson - -2014-03-01 warnes - - * [r1776] tests/test_mixedorder.R: Fix cut-and-paste error. - * [r1775] DESCRIPTION, inst/NEWS: Update files for gtools 3.3.1 - release - * [r1774] R/mixedsort.R, tests/test_mixedorder.R: Fix bug in - gtools::mixedorder regular expression for regognizing numbers. - (Periods weren't escaped). - -2014-02-11 warnes - - * [r1773] R/clean_up_dependencies2.R: Create and use locate copy of - tools:::.split_op_version. - * [r1772] inst/NEWS: Update for gtools 3.3.0. - * [r1771] man/getDependencies.Rd: Fix arguments - * [r1770] man/getDependencies.Rd: Update arguments to match code. - * [r1769] DESCRIPTION, NAMESPACE, R/clean_up_dependencies2.R, - R/getDependencies.R, man/getDependencies.Rd: Add - getDependencies() function to return a list of package - dependencies. - -2014-01-14 warnes - - * [r1768] DESCRIPTION, inst/NEWS: Update for bug-fix release - * [r1767] tests, tests/test_binsearch.R: Add test file for - binsearch() function. - * [r1766] R/binsearch.R: Fixed bug where binsearch() returned the - wrong endpoint & value when the found value was at the upper - endpoint. - -2014-01-13 warnes - - * [r1765] man/smartbind.Rd: Fix typo - -2014-01-11 warnes - - * [r1764] inst/NEWS: Update for gtools release 3.2.0 - * [r1763] man/gtools-defunct.Rd: fixes for R CMD check - * [r1762] DESCRIPTION, NAMESPACE, R/capture.R, R/defunct.R, - R/keywords.R, man/capture.Rd, man/gtools-defunct.Rd, - man/stars.pval.Rd: Fixes for gtools release 3.2.0 - -2013-12-23 warnes - - * [r1761] R/keywords.R, man/keywords.Rd: Extend the keywords() - function to return keywords associated with a specified topic via - 'keywords(topic)'. - * [r1760] man/stars.pval.Rd: Add keyword. - * [r1759] NAMESPACE, R/stars.pval.R, man/stars.pval.Rd: Add - stars.pval() function to convert p-values into significance - symbols. - -2013-11-26 warnes - - * [r1748] R/mixedsort.R: mixedorder() was failing to correctly - handle numbers including - decimals due to a faulty regular expression. Prior to the fix: - - > drr - [1] "Dose 0.3 mg" "Dose 0.04 mg" "Dose 0.5 mg" - > gtools::mixedsort(drr) - [1] "Dose 0.3 mg" "Dose 0.04 mg" "Dose 0.5 mg" - - After the fix: - - > drr - [1] "Dose 0.3 mg" "Dose 0.04 mg" "Dose 0.5 mg" - > mixedsort(drr) - [1] "Dose 0.04 mg" "Dose 0.3 mg" "Dose 0.5 mg" - - In addition, an optimization was added that checked if the input - vector - was numeric. If so, simply use the existing base::order function. - -2013-11-18 warnes - - * [r1747] R/capture.R: Use ".Deprecated" instead of warning. - -2013-11-06 warnes - - * [r1746] DESCRIPTION, inst/NEWS: Update files for gtools 3.1.1 - * [r1745] R/mixedsort.R: Fix problem with mixedorder/mixedsort when - there is only zero or one elements in the vector. - -2013-09-23 warnes - - * [r1716] man/gtools-deprecated.Rd: Comment out empty sections in - gtools-deprecated.Rd - * [r1715] DESCRIPTION, inst/NEWS: Update files for gtools 3.1.0 - release - * [r1714] man/addLast-deprecated.Rd, man/gtools-defunct.Rd, - man/gtools-deprecated.Rd, man/lastAdd.Rd: Make 'addLast()' - defunct. - * [r1713] R/addLast.R, R/lastAdd.R: Mark 'addLast()' as defunct and - move 'lastAdd()' function to a separate file. - * [r1712] DESCRIPTION, inst/NEWS: Update for gtools 3.0.1 release - * [r1711] R/mixedsort.R: Use 'suppressWarnings() instead of - 'options(warn=-1)' in 'mixedorder()'. - -2013-07-07 warnes - - * [r1705] man/lastAdd.Rd: Fix typo. - -2013-07-06 warnes - - * [r1704] man/lastAdd.Rd: Fix Rd warning. - * [r1703] NAMESPACE: Include lastAdd in NAMESPACE - * [r1702] R/deprecated.R: Change assert from deprecated to defunct. - * [r1701] R/addLast.R: Improve deprecation message - * [r1700] DESCRIPTION, inst/NEWS: Update for gtools 3.0.0 - * [r1699] R/addLast.R, man/addLast-deprecated.Rd, man/addLast.Rd, - man/gtools-defunct.Rd, man/gtools-deprecated.Rd, man/lastAdd.Rd: - Create new function lastAdd to replace addLast and mark addLast - as deprecated. - -2013-07-05 warnes - - * [r1698] inst/NEWS: Point out that addLast() modifies the value of - .Last in the global environment. - * [r1697] man/addLast.Rd: Point out that addLast() modifies the - value of .Last in the global environment. - * [r1696] DESCRIPTION, inst/NEWS: Update for gtools 2.7.2 mark 2 - * [r1695] man/logit.Rd: Remove cross-reference to (obsolete?) moc - package - * [r1694] DESCRIPTION, inst/NEWS: Update for gtools 2.7.2 - * [r1693] R/checkRVersion.R: Update for R version 3.0.0 and later - -2013-03-17 warnes - - * [r1640] R/smartbind.R: Fix error in smartbind: factor levels were - not being handled if the factor column was not present in the - first data frame. - -2012-06-19 warnes - - * [r1570] DESCRIPTION, inst/NEWS: Update for gtools 2.7.0. - * [r1569] man/smartbind.Rd: Document new 'verbose' argument to - smartbind(). - * [r1568] R/addLast.R, R/running.R: Clean up R CMD check warnings. - -2012-05-04 warnes - - * [r1529] R/smartbind.R: smartbind(): Improve handling of factors - and ordered factors. - -2011-10-05 warnes - - * [r1518] DESCRIPTION: Update version number for release - * [r1517] R/smartbind.R, man/smartbind.Rd: Add 'sep' argument to - smartbind() to allow specification of character used to separate - components of constructed names - -2011-09-28 warnes - - * [r1513] R/smartbind.R: smartbind(): Prevent coersion to data - frame from mangling column names. - * [r1512] R/smartbind.R, inst/NEWS: Add 'fill' argument to - smartbind() to specify a value to use for - missing entries. - * [r1511] DESCRIPTION, man/smartbind.Rd: Add 'fill' argument to - smartbind() to specify a value to use for - missing entries. - -2010-08-14 warnes - - * [r1451] R/mixedsort.R: Modify mixedorder()/mixedsort() to better - handle strings containing multiple periods, like version numbers - (e.g 1.1.2, 1.2.1. 1.1.1.1). - -2010-05-01 warnes - - * [r1434] DESCRIPTION: Update version number for new release - * [r1433] DESCRIPTION, man/addLast.Rd, man/ask.Rd, - man/binsearch.Rd, man/capture.Rd, man/combinations.Rd, - man/defmacro.Rd, man/dirichlet.Rd, man/foldchange.Rd, - man/invalid.Rd, man/keywords.Rd, man/logit.Rd, man/mixedsort.Rd, - man/oddeven.Rd, man/permute.Rd, man/quantcut.Rd, man/running.Rd, - man/scat.Rd, man/setTCPNoDelay.Rd, man/smartbind.Rd: Change - Greg's email address to gr...@wa... - * [r1432] R/checkRVersion.R: Fix error in checkRVersion() - -2010-04-28 ggrothendieck2 - - * [r1431] R/quantcut.R, R/strmacro.R, man/binsearch.Rd, - man/capture.Rd, man/setTCPNoDelay.Rd: fixed problems with R CMD - CHECK - -2009-05-09 warnes - - * [r1328] man/keywords.Rd: Escape $ in .Rd file to avoid latex - issues - * [r1327] ChangeLog, NEWS, inst/NEWS: Update NEWS and create - softlinks for NEWS and ChangeLog in top level directory - * [r1326] NEWS, inst, inst/NEWS: Move actual NEWS file into inst. - * [r1325] DESCRIPTION, man/addLast.Rd, man/binsearch.Rd, - man/capture.Rd, man/combinations.Rd, man/defmacro.Rd, - man/dirichlet.Rd, man/foldchange.Rd, man/gtools-deprecated.Rd, - man/invalid.Rd, man/logit.Rd, man/mixedsort.Rd, man/oddeven.Rd, - man/permute.Rd, man/quantcut.Rd, man/running.Rd, man/scat.Rd, - man/setTCPNoDelay.Rd, man/smartbind.Rd: Update Greg's email - address and fix Rd syntax errors - -2009-02-16 warnes - - * [r1313] src/Makevars.win: Correct windows make flags as suggested - by Brian Ripley. - -2008-08-15 warnes - - * [r1303] DESCRIPTION, NAMESPACE, R/keywords.R, man/keywords.Rd: - Add keywords() function to show /doc/KEYWORDS file - -2008-05-29 warnes - - * [r1285] R/newVersionAvailable.R: Add newVersionAvailable() - function to compare running and latest available R versions - -2008-05-26 warnes - - * [r1284] DESCRIPTION: Update license specification - * [r1283] man/assert-deprecated.Rd: Remove 'assert' man page - -2008-05-22 warnes - - * [r1282] man/assert.R: Finish rename of assert.R to - assert-depricated.Rd - * [r1281] R/checkRVersion.R: Add checkRVersion.R file - * [r1280] man/assert-deprecated.Rd: Rename again to get correct - extension! - * [r1279] NEWS: Update NEWS for 2.5.0 - * [r1278] man/checkRVersion.Rd: Add man page for checkRVersion - * [r1277] man/assert-deprecated.R, man/assert.R: Rename - assert-deprecated.R to assert.R to meet R file name requirements. - * [r1276] DESCRIPTION, NAMESPACE: Add checkRVersion to NAMESPACE, - and increment version in DESCRIPTION. - * [r1275] man/gtools-deprecated.Rd: Remove broken SEE LSO reference - -2008-04-12 warnes - - * [r1259] man/defmacro.Rd: Improve text explanation of how - defmacro() and strmacro() differ from - function(). - * [r1258] NEWS, man/assert-deprecated.R, man/assert.Rd, - man/gtools-deprecated.Rd: assert() is now deprecated in favor of - base::stopifnot() - * [r1257] R/assert.R, R/deprecated.R: Rename 'assert.R' to - 'deprecated.R'. - * [r1256] R/assert.R: Assert is now deprecated in favor of - base::stopifnot(), so add call to - .Deprecated() to inform the user. - -2007-11-30 warnes - - * [r1228] R/oddeven.R: Update defnitions of odd() and even() to use - modulus operator instead of division. Prettier, I think, :-D - -2007-08-08 warnes - - * [r1121] DESCRIPTION, R/binsearch.R: Fix bug identified by R-2.6's - check routings in binsearch() - * [r1120] DESCRIPTION, NAMESPACE, NEWS, R/binsearch.R, - man/binsearch.Rd: Add the binsearch(), previously in the genetics - package. - -2007-07-18 ggorjan - - * [r1100] man/combinations.Rd: typo fixed - -2007-04-12 warnes - - * [r1088] NAMESPACE, NEWS, R/ask.R, man/ask.Rd: Add ask() function - to prompt the user and collect a single response. - -2007-04-07 warnes - - * [r1087] DESCRIPTION, R/mixedsort.R: Fix improper escapes in - regexp detected by R 2.5.0 package check. - -2007-03-23 warnes - - * [r1083] R/combinations.R: Allow permutations for r>n provided - repeats.allowed=TRUE - -2006-11-28 warnes - - * [r1023] man/smartbind.Rd: Replace F with FALSE in smartbind - example. - -2006-11-27 warnes - - * [r1022] man/smartbind.Rd: Replace T with TRUE in smartbind - example - * [r1021] data/ELISA.rda: Temprary remove to reset binary flag - * [r1020] data/ELISA.rda: Temprary remove to reset binary flag - * [r1019] DESCRIPTION, NAMESPACE, NEWS, R/smartbind.R, - man/smartbind.Rd: Add smartbind() to list of exported functions, - and add corresponding - documentation file. - * [r1018] DESCRIPTION: Update my email address - -2006-11-14 ggorjan - - * [r1012] R/combinations.R, R/running.R, man/ELISA.Rd, - man/combinations.Rd: Removed executable property - -2006-08-02 warnes - - * [r977] man/addLast.Rd, man/assert.Rd, man/capture.Rd, - man/combinations.Rd, man/defmacro.Rd, man/dirichlet.Rd, - man/foldchange.Rd, man/invalid.Rd, man/logit.Rd, - man/mixedsort.Rd, man/oddeven.Rd, man/permute.Rd, - man/quantcut.Rd, man/running.Rd, man/scat.Rd, - man/setTCPNoDelay.Rd: Update my email address - -2006-05-05 nj7w - - * [r958] man/combinations.Rd: Fixed minor typo - in {value} - n was - replaced by r - * [r957] NAMESPACE, man/capture.Rd: Fixed minor typos - -2006-03-01 warnes - - * [r903] R/smartbind.R: Add smartbind function - -2006-01-18 warnes - - * [r845] man/mixedsort.Rd: Add concept tags to make mixedsort - easier to locate. - -2005-12-21 warnes - - * [r837] DESCRIPTION: Update version number and date - * [r836] NEWS: Note changes for 2.2.3 - * [r835] src/Makevars.win, src/setTCPNoDelay.c: Should now work on - Windows - -2005-12-20 warnes - - * [r834] src/setTCPNoDelay.c: Temporary fix to allow - setTCPNoDelay.c to compile on Windows. If compiled on windows - calling setTCPNoDelay will just raise an error. - -2005-12-14 warnes - - * [r813] src/setTCPNoDelay.c: Change C++ comment to standard - comment - -2005-12-13 nj7w - - * [r810] ChangeLog: *** empty log message *** - * [r809] NEWS: Updated NEWS and removed ChangeLog - -2005-12-12 nj7w - - * [r800] DESCRIPTION: Updated version for CRAN release - -2005-12-08 warnes - - * [r790] src, src/setTCPNoDelay.c: Add C source code for - setTCPNoDelay. - -2005-12-01 nj7w - - * [r776] man/combinations.Rd, man/foldchange.Rd, man/invalid.Rd, - man/logit.Rd, man/mixedsort.Rd, man/oddeven.Rd, man/quantcut.Rd, - man/running.Rd: Updated Greg's email address - -2005-11-29 warnes - - * [r769] NAMESPACE: Add UseDynLib to NAMESPACE so the shared - library gets properly loaded. - * [r768] R/setTCPNoDelay.R: - Remove debugging comments - - Change return value on success to "Success". - -2005-11-22 warnes - - * [r758] NAMESPACE: NAMESPACE - * [r757] NEWS: Update news for 2.2.1 release. - * [r756] man/addLast.Rd, man/setTCPNoDelay.Rd: Fixes for R CMD - check - * [r755] DESCRIPTION, NAMESPACE, R/setTCPNoDelay.R, - man/setTCPNoDelay.Rd: Add setTCPNoDelay() function and - documentation - * [r745] R/addLast.R, man/addLast.Rd: New function 'addLast' that - adds functions to R's .Last() so that - they will be executed when R is terminating. - -2005-09-22 warnes - - * [r678] DESCRIPTION, NAMESPACE, man/defmacro.Rd: More changes for - strmacro(), also changes for 2.1.1 release - * [r677] R/defmacro.R, R/strmacro.R, man/defmacro.Rd: Add strmaco() - which defines functions that use strings for macro definition - -2005-09-21 warnes - - * [r676] DESCRIPTION, R/defmacro.R, man/defmacro.Rd: Add support - for DOTS/... arguments to defmacro - -2005-09-12 nj7w - - * [r671] man/assert.Rd, man/dirichlet.Rd, man/permute.Rd, - man/scat.Rd: Updated Greg's email - -2005-09-02 nj7w - - * [r653] NAMESPACE: Exported assert - * [r652] DESCRIPTION: Updated the version number - * [r651] NEWS: Added NEWS - * [r650] ChangeLog: Added ChangeLog - * [r649] man/assert.Rd: Fixed syntax errors - -2005-09-02 warnes - - * [r648] R/assert.R, man/assert.Rd: Add assert() and documentation - * [r647] man/defmacro.Rd: Fix problem in defmacro.Rd file: don't - use \code{} in the example section. - -2005-08-31 warnes - - * [r645] DESCRIPTION, NAMESPACE, R/defmacro.R, man/defmacro.Rd: - Adding the defmacro() function, extracted from - - Lumley T. "Programmer's Niche: Macros in {R}", R News, 2001, Vol - 1, - No. 3, pp 11--13, \url{http://CRAN.R-project.org/doc/Rnews/} - * [r642] DESCRIPTION, DESCRIPTION.in: Add stand-alone DESCRIPTION - file and remove old DESCRIPTION.in file. - -2005-06-13 nj7w - - * [r626] R/mixedsort.R: Fixed a bug in mixedsort - check if - "which.na" and "which.blank" is numeric(0) before subsetting the - datasets. - -2005-06-09 nj7w - - * [r625] R/RSCompat.S, R/combinations.R, R/dirichlet.R, - R/foldchange.R, R/invalid.R, R/logit.R, R/mixedsort.R, - R/oddeven.R, R/permute.R, R/quantcut.R, R/running.R, R/scat.R, - man/ELISA.Rd, man/combinations.Rd, man/dirichlet.Rd, - man/foldchange.Rd, man/invalid.Rd, man/logit.Rd, - man/mixedsort.Rd, man/oddeven.Rd, man/permute.Rd, - man/quantcut.Rd, man/running.Rd, man/scat.Rd: Updating the - version number, and various help files to synchronize splitting - of gregmisc bundle in 4 individual components. - -2005-05-10 warnes - - * [r619] R/mixedsort.R: Fix handling of NA's in mixedorder. We were - using a high UTF character to try - to put NA's at the end of the sort order, but R 2.1.0 checks if - characters - are in the correct range. Instead, we explicitly force NA's to - the end. - -2005-04-07 warnes - - * [r606] NAMESPACE, R/scat.R, man/scat.Rd: - Add scat() function - which writes its arguments to stderr and - flushes so that output is immediately displayed, but only if - 'getOption("DEBUG")' is true. - -2005-04-02 warnes - - * [r600] NAMESPACE, R/drop.levels.R, man/drop.levels.Rd: Move - drop.levels() from gtools to gdata. - * [r599] R/mixedsort.R: Minor reordering of functions in file - * [r598] NAMESPACE, R/frameApply.R, man/frameApply.Rd: Move - frameApply() to gdata package. - * [r597] R/mixedsort.R: Fix error if only one value passed to - mixedorder. - * [r596] R/quantcut.R, man/quantcut.Rd: Add proper handling where - more than one quantile obtains the same value - -2005-04-01 warnes - - * [r595] man/ELISA.Rd, man/combinations.Rd, man/dirichlet.Rd, - man/drop.levels.Rd, man/foldchange.Rd, man/invalid.Rd, - man/logit.Rd, man/mixedsort.Rd, man/oddeven.Rd, man/permute.Rd, - man/quantcut.Rd, man/running.Rd: Add CVS ID tag to file headers. - * [r594] R/frameApply.R, man/frameApply.Rd: Fixes from Jim Rogers - for R CMD check problems in frameApply - -2005-03-31 warnes - - * [r591] R/drop.levels.R, R/frameApply.R, man/drop.levels.Rd, - man/frameApply.Rd: Updates to drop.levels() and frameApply() from - Jim Rogers - * [r590] data, data/ELISA.rda, man/ELISA.Rd: Add ELISA data set - used by frameApply and drop.levels examples - -2005-02-25 warnes - - * [r562] man/frameApply.Rd: Replace 'T' with TRUE. - * [r561] man/frameApply.Rd: Remove dependency on ELISA data set for - the example. - * [r558] NAMESPACE: Add drop.levels, frameApply to namespace - export. - -2005-02-15 warnes - - * [r542] R/drop.levels.R, R/frameApply.R, man/drop.levels.Rd, - man/frameApply.Rd: Add frameApply and drop.levels contributed by - Jim Rogers. - -2005-01-12 warnes - - * [r515] DESCRIPTION.in: Add dependency on R 1.9.0+ to prevent - poeple from installing on old - versions of R which don't support namespaces. - -2004-09-27 warneg - - * [r461] DESCRIPTION, DESCRIPTION.in, man/running.Rd: Updated to - pass R CMD check. - -2004-09-03 warneg - - * [r446] DESCRIPTION, NAMESPACE, R/dirichlet.R, R/foldchange.R, - R/invalid.R, R/mixedsort.R, R/oddeven.R, R/permute.R, - R/quantcut.R, R/running.R, man/running.Rd: initial bundle checkin - -2004-09-02 warneg - - * [r442] DESCRIPTION, DESCRIPTION.in, NAMESPACE: Initial revision - -2004-08-27 warnes - - * [r441] R/mixedsort.R, man/mixedsort.Rd: Fixed bug in mixedsort, - and modified reorder.factor to use mixedsort. - -2004-08-26 warnes - - * [r440] R/mixedsort.R: - Fix bug pointed out by Jim Rogers. - - Use a more distictive internal separator: $@$ instead of just $ - - Capitalization is now irrelevent for search order (unlike - ASCII). - -2004-06-08 warnes - - * [r372] R/running.R, man/running.Rd: Nitin Jain added by= - parameter to allow specifying separation between groups. - -2004-05-26 warnes - - * [r345] man/combinations.Rd: Escape underscores in email addresses - so Latex is happy. - * [r343] R/combinations.R: Replace 'T' with 'TRUE' to pass R CMD - check. - -2004-05-25 warnes - - * [r334] R/combinations.R: Remove extraneous comments. - * [r333] R/combinations.R: Fix an error in the code when using - repeats.allow=T and r>2. Bug - report and fix both due to Elizabeth Purdom - <ep...@st...>. - -2004-05-24 warnes - - * [r323] R/invalid.R: Check if argument is a vector before doing - is.na to avoid generating a warning. - * [r322] R/invalid.R, man/invalid.Rd: Add invalid() function for - testing if a parameter value is non-missing, non-NA, - non-NULL. - -2004-04-27 warnes - - * [r321] R/running.R, man/running.Rd: Replaced argument `as.list' - with `simplify'. Updated documentation, - and updated examples appropriately. - -2004-04-26 warnes - - * [r320] R/running.R, man/running.Rd: Added as.list argument to - return one list element per evaluation. - -2004-03-26 warnes - - * [r303] man/combinations.Rd: Uncomment and fix large 'n' example. - * [r301] man/running.Rd: - Update to match changes in running() - - Add examples to illustrate new arguments. - - Modify running correlation plot example to be more clear. - * [r299] R/running.R: More of the same. - * [r297] R/running.R: Fix bug discovered by Sean Davis - <sd...@ma...>. The running - function took an improper shortcut. When allow.fewer=FALSE it was - still passing shorter lists of elements to the called function, - and - then overwriting the results for the shorter lists with NAs. The - code - now skips evaluation of the function on lists shorter than the - specified length when allow.fewer=FALSE. - -2004-01-21 warnes - - * [r277] R/capture.R: - Mark sprint() as depreciated. - - Replace references to sprint with capture.output() - - Use match.arg for halign and valign arguments to - textplot.default. - - Fix textplot.character so that a vector of characters is - properly - displayed. Previouslt, character vectors were plotted on top of - each - other. - -2003-12-03 warnes - - * [r253] man/foldchange.Rd: - match function argument defaults with - 'usage' - -2003-11-21 warnes - - * [r237] man/foldchange.Rd: Removed 'deqn' call that was confusing - things. - * [r234] man/logit.Rd: Add email address to author field - * [r233] R/foldchange.R, man/foldchange.Rd: - new files - * [r232] R/mixedsort.R, man/mixedsort.Rd: - Change 'T' to 'TRUE' in - mixedsort.R - - Add missing brace in mixedsort.Rd - -2003-11-20 warnes - - * [r230] R/oddeven.R, man/oddeven.Rd: - Move 'odd' and 'even' - functions to a separate file & provide documentation - -2003-11-18 warnes - - * [r227] R/mixedsort.R, man/mixedsort.Rd: - Renamed smartsort to - mixedsort and added documentation. - -2003-11-10 warnes - - * [r220] R/capture.R, man/capture.Rd: - Add files contributed by - Arni Magnusson - <arnima@u.washington.edu>. As well as some of my own. - -2003-05-23 warnes - - * [r196] R/logit.R, man/logit.Rd: - library() backported from - 1.7-devel. This version of the function - adds the "pos=" argument to specify where in the search path the - library should be placed. - - - updated .First.lib to use library(...pos=3) for MASS to avoid - the - 'genotype' data set in MASS from masking the genotype funciton in - genetics when it loads gregmisc - - - Added logit() inv.logit() matchcols() function and - corresponding docs - -2003-04-22 warnes - - * [r189] man/combinations.Rd: - Fixed tpyo in example that allowed - combinations(500,2) to run when - it should have been ignred for testing.. - -2003-04-10 warnes - - * [r186] man/combinations.Rd: - Added note about the need to - increase options("expressions") to use - large values for 'n'. Prompted by bug report from Huan Huang - <hua...@bn... - -2003-04-04 warnes - - * [r183] R/RSCompat.S: - Replace 'T' with 'TRUE' - * [r182] R/dirichlet.R: - Change occurences of 'T' to 'TRUE' - * [r181] man/capture.Rd: - Allow optional arguments to sprint to be - passed to print - - Fix R CMD check errors - * [r180] R/capture.R: - Allow optional arguments to sprint to be - passed to print - -2003-04-03 warnes - - * [r177] man/capture.Rd: - Had mistyped 'sprint' as 'sprintf'. - * [r176] man/capture.Rd: - Add help file for capture and sprintf. - -2003-04-02 warnes - - * [r174] R/capture.R: - Added file 'capture.R' containing capture() - and sprint(). - -2003-03-07 warnes - - * [r168] R/RSCompat.S: - Minor changes to code to allow the package - to be provided as an - S-Plus chapter. - -2003-01-30 warnes - - * [r161] man/running.Rd: - Fixed typo in email address. - -2003-01-02 warnes - - * [r148] R/RSCompat.S: - Add nlevels function. - -2002-10-11 warnes - - * [r133] R/permute.R, man/permute.Rd: - Add permute() function - (wraper for sample) and man page - * [r132] man/dirichlet.Rd: - Escaped underscores in my email - address that was causing a parse - error in the {r,p}dirichlet man page. - -2002-09-30 warnes - - * [r128] R/dirichlet.R, man/dirichlet.Rd: - Added rdirichlet() and - ddirichlet() with accompaning help page and tests. - -2002-09-24 warnes - - * [r122] R/running.R: - Fixed error where running was always - calling running2 with - 'fun=mean', ignoring the specified funtion. - -2002-09-23 warnes - - * [r117] man/combinations.Rd, man/quantcut.Rd: - Modified all files - to include CVS Id and Log tags. - * [r116] R/combinations.R: - Added CrossTable() and barplot2() code - and docs contributed by Marc Schwartz. - - Permit combinations() to be used when r>n provided - repeat.allowed=TRUE - - Bumped up version number - -2002-08-01 warnes - - * [r114] R/running.R: - Corrected documentation mismatch for ci, - ci.default. - - - Replaced all occurences of '_' for assignment with '<-'. - - - Replaced all occurences of 'T' or 'F' for 'TRUE' and 'FALSE' - with - the spelled out version. - - - Updaded version number and date. - -2002-04-09 warneg - - * [r109] R/combinations.R, man/combinations.Rd, man/running.Rd: - Checkin for version 0.5.3 - -2002-03-26 warneg - - * [r97] man/quantcut.Rd: Initial Checkin - * [r96] R/quantcut.R: Initial checkin. - -2002-03-20 warneg - - * [r91] R/RSCompat.S: - Added definition of is.R function. - - - Added boxplot.formula - -2002-03-07 warneg - - * [r90] man/running.Rd: - Added documentation and example for - running2 - * [r89] R/running.R: - Added "running2", which handles both - univariate and bivariate cases - - Modified "running" to call "running2" - -2002-02-05 warneg - - * [r75] R/RSCompat.S: - Fix typo that caused code meant to run only - under S-Plus to run - under R, causing problems. - -2001-12-19 warneg - - * [r67] R/RSCompat.S: - Added code for %in%. - -2001-09-18 warneg - - * [r18] R/RSCompat.S: Release 0.3.2 - -2001-09-01 warneg - - * [r17] R/RSCompat.S: Initial checkin. - * [r16] R/running.R, man/running.Rd: Release 0.3.0 - -2001-08-25 warneg - - * [r13] R/running.R: Initial CVS checkin. - * [r11] man/combinations.Rd: Fixed a typo and a syntax error. - * [r7] man/running.Rd: Initial Checkin - -2001-06-29 warneg - - * [r6] ., R, R/combinations.R, man, man/combinations.Rd: Initial - revision. - Modified: trunk/gtools/man/mixedsort.Rd =================================================================== --- trunk/gtools/man/mixedsort.Rd 2015-04-25 17:16:31 UTC (rev 1974) +++ trunk/gtools/man/mixedsort.Rd 2015-04-28 04:16:56 UTC (rev 1975) @@ -6,21 +6,28 @@ \title{Order or Sort strings with embedded numbers so that the numbers are in the correct order} \description{ - These functions sort or order character strings containing numbers so - that the numbers are numerically sorted rather than sorted by - character value. I.e. "Asprin 50mg" will come before "Asprin 100mg". - In addition, case of character strings is ignored so that "a", will - come before "B" and "C". + These functions sort or order character strings containing embedded + numbers so that the numbers are numerically sorted rather than sorted + by character value. I.e. "Asprin 50mg" will come before + "Asprin 100mg". In addition, case of character strings is ignored so + that "a", will come before "B" and "C". } \usage{ -mixedsort(x) +mixedsort(x, decreasing=FALSE, na.last=TRUE, blank.last=FALSE, ...) +mixedorder(x, decreasing=FALSE, na.last=TRUE, blank.last=FALSE, ...) } \arguments{ - \item{x}{ Character vector to be sorted } + \item{x}{Vector to be sorted.} + \item{decreasing}{logical. Should the sort be increasing or + decreasing? Note that \code{descending=TRUE} reverses the meanings of + \code{na.lst} and \code{blanks.last}.} + \item{na.last}{for controlling the treatment of ‘NA’s. If ‘TRUE’, missing + values in the data are put last; if ‘FALSE’, they are put + first; if ‘NA’, they are removed.} } \details{ - I often have character vectors (e.g. factor labels) that contain - both text and numeric data, such as compound and dose. This function + I often have character vectors (e.g. factor labels), such as compound + and dose, that contain both text and numeric data. This function is useful for sorting these character vectors into a logical order. It does so by splitting each character vector into a sequence of @@ -29,8 +36,10 @@ "100"), followed by characters strings sorted by character value (e.g. "A" comes before "B"). - Empty strings are always sorted to the front of the list, and \code{NA} - values to the end. + By default, sort order is ascending, empty strings are sorted to the front, + and \code{NA} values to the end. Setting \code{descending=TRUE} + changes the sort order to descending and reverses the meanings of + \code{na.last} and \code{blank.last}. } \value{ \code{mixedorder} returns a vector giving the sort order of the input @@ -39,27 +48,38 @@ \author{ Gregory R. Warnes \email{gr...@wa...} } \seealso{ \code{\link[base]{sort}}, \code{\link[base]{order}} } \examples{ -# compound & dose labels +## compound & dose labels Treatment <- c("Control", "Asprin 10mg/day", "Asprin 50mg/day", "Asprin 100mg/day", "Acetomycin 100mg/day", "Acetomycin 1000mg/day") -# ordinary sort puts the dosages in the wrong order +## ordinary sort puts the dosages in the wrong order sort(Treatment) -# but mixedsort does the 'right' thing +## but mixedsort does the 'right' thing mixedsort(Treatment) -# Here is a more complex example +## Here is a more complex example x <- rev(c("AA 0.50 ml", "AA 1.5 ml", "AA 500 ml", "AA 1500 ml", "EXP 1", "AA 1e3 ml", "A A A", "1 2 3 A", "NA", NA, "1e2", "", "-", "1A", "1 A", "100", "100A", "Inf")) mixedorder(x) -mixedsort(x) -# notice that plain numbers, including 'Inf' show up before strings. +mixedsort(x) # Notice that plain numbers, including 'Inf' show up + # before strings, NAs at the end, and blanks at the + # beginning . + +mixedsort(x, na.last=TRUE) # default +mixedsort(x, na.last=FALSE) # push NAs to the front + + +mixedsort(x, blank.last=FALSE) # default +mixedsort(x, blank.last=TRUE) # push blanks to the end + +mixedsort(x, decreasing=FALSE) # default +mixedsort(x, decreasing=TRUE) # reverse sort order } \keyword{univar} \keyword{manip} Added: trunk/gtools/src/roman2int.c =================================================================== --- trunk/gtools/src/roman2int.c (rev 0) +++ trunk/gtools/src/roman2int.c 2015-04-28 04:16:56 UTC (rev 1975) @@ -0,0 +1,62 @@ +#include <R.h> + +void convert( + char** letters, + int* nchar, + int* values + ) +{ + if(*nchar<1) return; + + for(int i=0; i<*nchar; i++) + { + if(letters[0][i]== 'I') + values[i]=1; + else if(letters[0][i]== 'V') + values[i]=5; + else if(letters[0][i]== 'X') + values[i]=10; + else if(letters[0][i]== 'L') + values[i]=50; + else if(letters[0][i]== 'C') + values[i]=100; + else if(letters[0][i]== 'D') + values[i]=500; + else if(letters[0][i]== 'M') + values[i]=1000; + else error("Invalid roman numeral '%c'", letters[0][i]); + } +} + +void roman2int(char** str, + int* nchar, + int* retval) +{ + if (*nchar < 1) + { + *retval = NA_INTEGER; + return; + } + + int* values = (int*) R_alloc(*nchar, sizeof(int)); + convert(str, nchar, values); + + int total=0; + if (*nchar > 1) + { + for(int n=0; n<*nchar-1; n++) + { + if(values[n]<values[n+1]) + { + total-=values[n]; + } + else + { + total+=values[n]; + } + } + } + total += values[*nchar-1]; + + retval[0] = total; +} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 17:16:38
|
Revision: 1974 http://sourceforge.net/p/r-gregmisc/code/1974 Author: warnes Date: 2015-04-25 17:16:31 +0000 (Sat, 25 Apr 2015) Log Message: ----------- List needs a conjuction Modified Paths: -------------- trunk/gdata/DESCRIPTION Modified: trunk/gdata/DESCRIPTION =================================================================== --- trunk/gdata/DESCRIPTION 2015-04-25 17:13:07 UTC (rev 1973) +++ trunk/gdata/DESCRIPTION 2015-04-25 17:16:31 UTC (rev 1974) @@ -17,7 +17,7 @@ - matrix operations ('unmatrix', 'upperTriangle', 'lowerTriangle'), - operations on vectors ('case', 'unknownToNA', 'duplicated2', 'trimSum'), - operations on data frames ('frameApply', 'wideByFactor'), - - value of last evaluated expression ('ans'), + - value of last evaluated expression ('ans'), and - wrapper for 'sample' that ensures consistent behavior for both scalar and vector arguments ('resample'). Depends: R (>= 2.13.0) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 17:13:08
|
Revision: 1973 http://sourceforge.net/p/r-gregmisc/code/1973 Author: warnes Date: 2015-04-25 17:13:07 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Fix spelling errors & typos Modified Paths: -------------- trunk/gdata/inst/NEWS Modified: trunk/gdata/inst/NEWS =================================================================== --- trunk/gdata/inst/NEWS 2015-04-25 16:54:38 UTC (rev 1972) +++ trunk/gdata/inst/NEWS 2015-04-25 17:13:07 UTC (rev 1973) @@ -3,13 +3,13 @@ New features: -- New functions first() and last() to retrun the first or last +- New functions first() and last() to return the first or last element of a vector or list. - New functions left() and right() to return the leftmost or rightmost n (default to 6) columns of a matrix or dataframe. -- New 'scienfic' argument to write.fwf(). Set 'scientific=FALSE' to +- New 'scientific' argument to write.fwf(). Set 'scientific=FALSE' to prevent numeric columns from being displayed using scientific notification. @@ -24,7 +24,7 @@ - New 'units' argument to humanReadable()--and hence to print.object_sizes() and format.object_sizes()--that permits specifying the unit to use for all values. Use 'bytes' to display - all valus with the unit 'bytes', use 'auto' (or leave it missing) to + all values with the unit 'bytes', use 'auto' (or leave it missing) to automatically select the best unit, and use a unit from the selected standard to use that unit (i.e. 'MiB'). @@ -45,13 +45,13 @@ Other changes: -- Replaced depricated PERL function POSIX::isdigit in xls2csv.pl +- Replaced deprecated PERL function POSIX::isdigit in xls2csv.pl (which is used by read.xls() ) with an equivalent regular expression. (Reported by both Charles Plessy, Gerrit-jan Schutten, and Paul Johnson. Charles also provided a patch to correct the issue.) -- aggregate.table(), which has been defuct gdate 2.13.3 (2014-04-04) +- aggregate.table(), which has been defunct gdate 2.13.3 (2014-04-04) has now been completely removed. Changes in 2.14.0 (2014-08-27) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 16:54:40
|
Revision: 1972 http://sourceforge.net/p/r-gregmisc/code/1972 Author: warnes Date: 2015-04-25 16:54:38 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Fix typographical errors Modified Paths: -------------- trunk/gdata/DESCRIPTION Modified: trunk/gdata/DESCRIPTION =================================================================== --- trunk/gdata/DESCRIPTION 2015-04-25 16:51:44 UTC (rev 1971) +++ trunk/gdata/DESCRIPTION 2015-04-25 16:54:38 UTC (rev 1972) @@ -11,7 +11,7 @@ - manipulating MS-Excel formatted files ('read.xls', 'installXLSXsupport', 'sheetCount', 'xlsFormats'), - generating fixed-width format files ('write.fwf'), - - extrating compoents of date & time objects ('getYear', 'getMonth', + - extricating components of date & time objects ('getYear', 'getMonth', 'getDay', 'getHour', 'getMin', 'getSec'), - operations on columns of data frames ('matchcols', 'rename.vars'), - matrix operations ('unmatrix', 'upperTriangle', 'lowerTriangle'), This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 16:51:51
|
Revision: 1971 http://sourceforge.net/p/r-gregmisc/code/1971 Author: warnes Date: 2015-04-25 16:51:44 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Update NEWS and ChangeLog (again) Modified Paths: -------------- trunk/gdata/inst/ChangeLog trunk/gdata/inst/NEWS Modified: trunk/gdata/inst/ChangeLog =================================================================== --- trunk/gdata/inst/ChangeLog 2015-04-25 16:49:59 UTC (rev 1970) +++ trunk/gdata/inst/ChangeLog 2015-04-25 16:51:44 UTC (rev 1971) @@ -1,3 +1,66 @@ +2015-04-25 16:24 warnes + + * R/write.fwf.R: Missed on commit. + +2015-04-25 16:23 warnes + + * R/write.fwf.R, tests/test.humanReadable.Rout.save, + tests/test.reorder.factor.Rout.save, + tests/tests.write.fwf.Rout.save, + tests/unitTests/runit.write.fwf.R: Modfy write.fwf() to properly + handle matrix argument, avoiding conversion to dataframe unless + rownames=TRUE. Add corresponding unit tests. + +2015-04-25 09:11 warnes + + * inst/perl/module_tools.pl: Installing PERL modules was failing. + Adding CPAN configuration option fixed the problem. + +2015-04-25 08:49 warnes + + * inst/perl/xls2csv.pl: Error message about executable name was + missing one alternative + +2015-04-25 07:59 warnes + + * DESCRIPTION: Better describe gdata contents + +2015-04-25 07:58 warnes + + * NAMESPACE: is.* and as.* aren't generics + +2015-04-25 07:57 warnes + + * man/humanReadable.Rd, man/object.size.Rd: Add 'justify' argument + to print and format object_sizes methods + +2015-04-25 07:57 warnes + + * R/humanReadable.R, R/object.size.R: Add 'justify' argument to + print and format object_sizes methods + +2015-04-25 07:56 warnes + + * R/write.fwf.R: Remove stray call to 'browser' + +2015-04-25 06:26 warnes + + * DESCRIPTION, inst/ChangeLog, inst/NEWS: Update DESCRIPTION, + ChangeLog, and NEWS + +2015-04-25 05:54 warnes + + * NAMESPACE, R/humanReadable.R, R/object.size.R, + man/humanReadable.Rd, man/object.size.Rd, + tests/test.humanReadable.R, tests/test.humanReadable.Rout.save: + Complete work on object.size(), object_sizes methods, and + humanReadable. + +2015-04-25 02:52 warnes + + * inst/perl/Spreadsheet/ParseExcel.pm: Add error message if Excel + file format is too old + 2015-04-23 22:49 warnes * inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog Modified: trunk/gdata/inst/NEWS =================================================================== --- trunk/gdata/inst/NEWS 2015-04-25 16:49:59 UTC (rev 1970) +++ trunk/gdata/inst/NEWS 2015-04-25 16:51:44 UTC (rev 1971) @@ -51,6 +51,8 @@ and Paul Johnson. Charles also provided a patch to correct the issue.) +- aggregate.table(), which has been defuct gdate 2.13.3 (2014-04-04) + has now been completely removed. Changes in 2.14.0 (2014-08-27) ------------------------------ This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 16:50:06
|
Revision: 1970 http://sourceforge.net/p/r-gregmisc/code/1970 Author: warnes Date: 2015-04-25 16:49:59 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Remove aggregate.table() entirely Modified Paths: -------------- trunk/gdata/NAMESPACE Removed Paths: ------------- trunk/gdata/R/aggregate.table.R Modified: trunk/gdata/NAMESPACE =================================================================== --- trunk/gdata/NAMESPACE 2015-04-25 16:46:12 UTC (rev 1969) +++ trunk/gdata/NAMESPACE 2015-04-25 16:49:59 UTC (rev 1970) @@ -3,7 +3,6 @@ .onAttach, ans, Args, - aggregate.table, bindData, case, cbindX, Deleted: trunk/gdata/R/aggregate.table.R =================================================================== --- trunk/gdata/R/aggregate.table.R 2015-04-25 16:46:12 UTC (rev 1969) +++ trunk/gdata/R/aggregate.table.R 2015-04-25 16:49:59 UTC (rev 1970) @@ -1,39 +0,0 @@ -# $Id$ - -aggregate.table <- function(x, by1, by2, FUN=mean, ...) - { - .Defunct( - new=paste( - "tapply(X=", - deparse(substitute(x)), - ", INDEX=list(", - deparse(substitute(by1)), - ", ", - deparse(substitute(by2)), - "), FUN=", - deparse(substitute(FUN)), - if(length(list(...))>0) - { - l <- list(...) - paste(", ", - paste(names(l),"=", - deparse(substitute(...)), - sep="", - collapse=", ") - ) - }, - ")", sep=""), - package="gdata" - ) - } - -## aggregate.table <- function(x, by1, by2, FUN=mean, ... ) -## { -## -## tab <- matrix( nrow=nlevels(by1), ncol=nlevels(by2) ) -## dimnames(tab) <- list(levels(by1),levels(by2)) -## -## for(i in 1:nrow(ag)) -## tab[ as.character(ag[i,1]), as.character(ag[i,2]) ] <- ag[i,3] -## tab -## } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 16:46:19
|
Revision: 1969 http://sourceforge.net/p/r-gregmisc/code/1969 Author: warnes Date: 2015-04-25 16:46:12 +0000 (Sat, 25 Apr 2015) Log Message: ----------- 'test.humanReadable.R' needed set.seed() to make the results consistent. Modified Paths: -------------- trunk/gdata/tests/test.humanReadable.R trunk/gdata/tests/test.humanReadable.Rout.save trunk/gdata/tests/test.read.xls.Rout.save trunk/gdata/tests/test.reorder.factor.Rout.save trunk/gdata/tests/tests.write.fwf.Rout.save Modified: trunk/gdata/tests/test.humanReadable.R =================================================================== --- trunk/gdata/tests/test.humanReadable.R 2015-04-25 16:37:00 UTC (rev 1968) +++ trunk/gdata/tests/test.humanReadable.R 2015-04-25 16:46:12 UTC (rev 1969) @@ -2,6 +2,8 @@ options(humanReadable=FALSE) +set.seed(123456) + baseSI <- 10 powerSI <- seq(from=0, to=27, by=3) SI0 <- (baseSI)^powerSI Modified: trunk/gdata/tests/test.humanReadable.Rout.save =================================================================== --- trunk/gdata/tests/test.humanReadable.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) +++ trunk/gdata/tests/test.humanReadable.Rout.save 2015-04-25 16:46:12 UTC (rev 1969) @@ -33,6 +33,8 @@ > > options(humanReadable=FALSE) > +> set.seed(123456) +> > baseSI <- 10 > powerSI <- seq(from=0, to=27, by=3) > SI0 <- (baseSI)^powerSI @@ -58,26 +60,26 @@ + humanReadable(x=IEC2, standard="Unix", width=3)) [,1] [,2] [,3] [,4] [,5] [,6] [1,] " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " - [2,] " 1.2793 kB" "1.279 kB" " 1.3 kB" " 1.2233 KiB" "1.223 KiB" " 1.2 KiB" - [3,] "1.20319 MB" "1.203 MB" " 1.2 MB" "1.29885 MiB" "1.299 MiB" " 1.3 MiB" - [4,] "1.16832 GB" "1.168 GB" " 1.2 GB" "1.22854 GiB" "1.229 GiB" " 1.2 GiB" - [5,] "1.68539 TB" "1.685 TB" " 1.7 TB" "1.49459 TiB" "1.495 TiB" " 1.5 TiB" - [6,] "1.20409 PB" "1.204 PB" " 1.2 PB" "1.30007 PiB" " 1.3 PiB" " 1.3 PiB" - [7,] " 1.4313 EB" "1.431 EB" " 1.4 EB" " 1.3716 EiB" "1.372 EiB" " 1.4 EiB" - [8,] "1.19649 ZB" "1.196 ZB" " 1.2 ZB" "1.26321 ZiB" "1.263 ZiB" " 1.3 ZiB" - [9,] "1.17615 YB" "1.176 YB" " 1.2 YB" "1.30608 YiB" "1.306 YiB" " 1.3 YiB" -[10,] "1270.14 YB" " 1270 YB" "1270 YB" " 1373.7 YiB" " 1374 YiB" "1374 YiB" + [2,] "1.54215 kB" "1.542 kB" " 1.5 kB" "1.18582 KiB" "1.186 KiB" " 1.2 KiB" + [3,] "1.20064 MB" "1.201 MB" " 1.2 MB" "1.19003 MiB" " 1.19 MiB" " 1.2 MiB" + [4,] "1.25207 GB" "1.252 GB" " 1.3 GB" "1.54448 GiB" "1.544 GiB" " 1.5 GiB" + [5,] "1.18121 TB" "1.181 TB" " 1.2 TB" "1.27667 TiB" "1.277 TiB" " 1.3 TiB" + [6,] " 1.1853 PB" "1.185 PB" " 1.2 PB" "1.18733 PiB" "1.187 PiB" " 1.2 PiB" + [7,] " 1.1678 EB" "1.168 EB" " 1.2 EB" "1.46271 EiB" "1.463 EiB" " 1.5 EiB" + [8,] "1.18275 ZB" "1.183 ZB" " 1.2 ZB" "1.62382 ZiB" "1.624 ZiB" " 1.6 ZiB" + [9,] "1.18568 YB" "1.186 YB" " 1.2 YB" "1.19557 YiB" "1.196 YiB" " 1.2 YiB" +[10,] "1501.49 YB" " 1501 YB" "1501 YB" "1750.35 YiB" " 1750 YiB" "1750 YiB" [,7] [,8] [,9] [1,] " 2 B" " 2 B" " 2 B" - [2,] " 1.2233 K" "1.223 K" " 1.2 K" - [3,] "1.29885 M" "1.299 M" " 1.3 M" - [4,] "1.22854 G" "1.229 G" " 1.2 G" - [5,] "1.49459 T" "1.495 T" " 1.5 T" - [6,] "1.30007 P" " 1.3 P" " 1.3 P" - [7,] " 1.3716 E" "1.372 E" " 1.4 E" - [8,] "1.26321 Z" "1.263 Z" " 1.3 Z" - [9,] "1.30608 Y" "1.306 Y" " 1.3 Y" -[10,] " 1373.7 Y" " 1374 Y" "1374 Y" + [2,] "1.18582 K" "1.186 K" " 1.2 K" + [3,] "1.19003 M" " 1.19 M" " 1.2 M" + [4,] "1.54448 G" "1.544 G" " 1.5 G" + [5,] "1.27667 T" "1.277 T" " 1.3 T" + [6,] "1.18733 P" "1.187 P" " 1.2 P" + [7,] "1.46271 E" "1.463 E" " 1.5 E" + [8,] "1.62382 Z" "1.624 Z" " 1.6 Z" + [9,] "1.19557 Y" "1.196 Y" " 1.2 Y" +[10,] "1750.35 Y" " 1750 Y" "1750 Y" > > # Auto units, specify digits > cbind(humanReadable(x=SI2, standard="SI", width=NULL, digits=7), @@ -94,37 +96,37 @@ + humanReadable(x=IEC2, standard="Unix", width=NULL, digits=1)) [,1] [,2] [,3] [,4] [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " - [2,] " 1.2793050 kB" " 1.279 kB" " 1.28 kB" " 1.3 kB" - [3,] " 1.2031896 MB" " 1.203 MB" " 1.20 MB" " 1.2 MB" - [4,] " 1.1683216 GB" " 1.168 GB" " 1.17 GB" " 1.2 GB" - [5,] " 1.6853920 TB" " 1.685 TB" " 1.69 TB" " 1.7 TB" - [6,] " 1.2040855 PB" " 1.204 PB" " 1.20 PB" " 1.2 PB" - [7,] " 1.4313005 EB" " 1.431 EB" " 1.43 EB" " 1.4 EB" - [8,] " 1.1964931 ZB" " 1.196 ZB" " 1.20 ZB" " 1.2 ZB" - [9,] " 1.1761521 YB" " 1.176 YB" " 1.18 YB" " 1.2 YB" -[10,] "1270.1414519 YB" "1270.141 YB" "1270.14 YB" "1270.1 YB" + [2,] " 1.5421535 kB" " 1.542 kB" " 1.54 kB" " 1.5 kB" + [3,] " 1.2006426 MB" " 1.201 MB" " 1.20 MB" " 1.2 MB" + [4,] " 1.2520737 GB" " 1.252 GB" " 1.25 GB" " 1.3 GB" + [5,] " 1.1812105 TB" " 1.181 TB" " 1.18 TB" " 1.2 TB" + [6,] " 1.1853010 PB" " 1.185 PB" " 1.19 PB" " 1.2 PB" + [7,] " 1.1678048 EB" " 1.168 EB" " 1.17 EB" " 1.2 EB" + [8,] " 1.1827531 ZB" " 1.183 ZB" " 1.18 ZB" " 1.2 ZB" + [9,] " 1.1856788 YB" " 1.186 YB" " 1.19 YB" " 1.2 YB" +[10,] "1501.4852409 YB" "1501.485 YB" "1501.49 YB" "1501.5 YB" [,5] [,6] [,7] [,8] [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " - [2,] " 1.2232984 KiB" " 1.223 KiB" " 1.22 KiB" " 1.2 KiB" - [3,] " 1.2988465 MiB" " 1.299 MiB" " 1.30 MiB" " 1.3 MiB" - [4,] " 1.2285433 GiB" " 1.229 GiB" " 1.23 GiB" " 1.2 GiB" - [5,] " 1.4945944 TiB" " 1.495 TiB" " 1.49 TiB" " 1.5 TiB" - [6,] " 1.3000707 PiB" " 1.300 PiB" " 1.30 PiB" " 1.3 PiB" - [7,] " 1.3716001 EiB" " 1.372 EiB" " 1.37 EiB" " 1.4 EiB" - [8,] " 1.2632150 ZiB" " 1.263 ZiB" " 1.26 ZiB" " 1.3 ZiB" - [9,] " 1.3060808 YiB" " 1.306 YiB" " 1.31 YiB" " 1.3 YiB" -[10,] "1373.6975294 YiB" "1373.698 YiB" "1373.70 YiB" "1373.7 YiB" + [2,] " 1.1858248 KiB" " 1.186 KiB" " 1.19 KiB" " 1.2 KiB" + [3,] " 1.1900302 MiB" " 1.190 MiB" " 1.19 MiB" " 1.2 MiB" + [4,] " 1.5444791 GiB" " 1.544 GiB" " 1.54 GiB" " 1.5 GiB" + [5,] " 1.2766723 TiB" " 1.277 TiB" " 1.28 TiB" " 1.3 TiB" + [6,] " 1.1873270 PiB" " 1.187 PiB" " 1.19 PiB" " 1.2 PiB" + [7,] " 1.4627144 EiB" " 1.463 EiB" " 1.46 EiB" " 1.5 EiB" + [8,] " 1.6238214 ZiB" " 1.624 ZiB" " 1.62 ZiB" " 1.6 ZiB" + [9,] " 1.1955693 YiB" " 1.196 YiB" " 1.20 YiB" " 1.2 YiB" +[10,] "1750.3547972 YiB" "1750.355 YiB" "1750.35 YiB" "1750.4 YiB" [,9] [,10] [,11] [,12] [1,] " 1.5000000 B" " 1.500 B" " 1.50 B" " 1.5 B" - [2,] " 1.2232984 K" " 1.223 K" " 1.22 K" " 1.2 K" - [3,] " 1.2988465 M" " 1.299 M" " 1.30 M" " 1.3 M" - [4,] " 1.2285433 G" " 1.229 G" " 1.23 G" " 1.2 G" - [5,] " 1.4945944 T" " 1.495 T" " 1.49 T" " 1.5 T" - [6,] " 1.3000707 P" " 1.300 P" " 1.30 P" " 1.3 P" - [7,] " 1.3716001 E" " 1.372 E" " 1.37 E" " 1.4 E" - [8,] " 1.2632150 Z" " 1.263 Z" " 1.26 Z" " 1.3 Z" - [9,] " 1.3060808 Y" " 1.306 Y" " 1.31 Y" " 1.3 Y" -[10,] "1373.6975294 Y" "1373.698 Y" "1373.70 Y" "1373.7 Y" + [2,] " 1.1858248 K" " 1.186 K" " 1.19 K" " 1.2 K" + [3,] " 1.1900302 M" " 1.190 M" " 1.19 M" " 1.2 M" + [4,] " 1.5444791 G" " 1.544 G" " 1.54 G" " 1.5 G" + [5,] " 1.2766723 T" " 1.277 T" " 1.28 T" " 1.3 T" + [6,] " 1.1873270 P" " 1.187 P" " 1.19 P" " 1.2 P" + [7,] " 1.4627144 E" " 1.463 E" " 1.46 E" " 1.5 E" + [8,] " 1.6238214 Z" " 1.624 Z" " 1.62 Z" " 1.6 Z" + [9,] " 1.1955693 Y" " 1.196 Y" " 1.20 Y" " 1.2 Y" +[10,] "1750.3547972 Y" "1750.355 Y" "1750.35 Y" "1750.4 Y" > > # Single unit, specify width > cbind(humanReadable(x=SI1, units="GB", standard="SI", width=7), @@ -139,25 +141,25 @@ + ) [,1] [,2] [,3] [,4] [,5] [,6] [1,] "5e-10 GB" "5e-10 GB" "5e-10 GB" "5e-10 GiB" "5e-10 GiB" "5e-10 GiB" - [2,] "7e-07 GB" "7e-07 GB" "7e-07 GB" "7e-07 GiB" "7e-07 GiB" "7e-07 GiB" - [3,] "7e-04 GB" "7e-04 GB" "7e-04 GB" "8e-04 GiB" "8e-04 GiB" "8e-04 GiB" - [4,] "4e-01 GB" "4e-01 GB" "4e-01 GB" "7e-01 GiB" "7e-01 GiB" "7e-01 GiB" - [5,] "7e+02 GB" "7e+02 GB" "7e+02 GB" "7e+02 GiB" "7e+02 GiB" "7e+02 GiB" - [6,] "7e+05 GB" "7e+05 GB" "7e+05 GB" "4e+05 GiB" "4e+05 GiB" "4e+05 GiB" - [7,] "8e+08 GB" "8e+08 GB" "8e+08 GB" "6e+08 GiB" "6e+08 GiB" "6e+08 GiB" + [2,] "8e-07 GB" "8e-07 GB" "8e-07 GB" "6e-07 GiB" "6e-07 GiB" "6e-07 GiB" + [3,] "8e-04 GB" "8e-04 GB" "8e-04 GB" "8e-04 GiB" "8e-04 GiB" "8e-04 GiB" + [4,] "7e-01 GB" "7e-01 GB" "7e-01 GB" "4e-01 GiB" "4e-01 GiB" "4e-01 GiB" + [5,] "6e+02 GB" "6e+02 GB" "6e+02 GB" "3e+02 GiB" "3e+02 GiB" "3e+02 GiB" + [6,] "6e+05 GB" "6e+05 GB" "6e+05 GB" "4e+05 GiB" "4e+05 GiB" "4e+05 GiB" + [7,] "5e+08 GB" "5e+08 GB" "5e+08 GB" "5e+08 GiB" "5e+08 GiB" "5e+08 GiB" [8,] "7e+11 GB" "7e+11 GB" "7e+11 GB" "8e+11 GiB" "8e+11 GiB" "8e+11 GiB" - [9,] "4e+14 GB" "4e+14 GB" "4e+14 GB" "8e+14 GiB" "8e+14 GiB" "8e+14 GiB" -[10,] "7e+17 GB" "7e+17 GB" "7e+17 GB" "9e+17 GiB" "9e+17 GiB" "9e+17 GiB" + [9,] "3e+14 GB" "3e+14 GB" "3e+14 GB" "9e+14 GiB" "9e+14 GiB" "9e+14 GiB" +[10,] "8e+17 GB" "8e+17 GB" "8e+17 GB" "9e+17 GiB" "9e+17 GiB" "9e+17 GiB" [,7] [,8] [,9] [1,] "5e-10 G" "5e-10 G" "5e-10 G" - [2,] "7e-07 G" "7e-07 G" "7e-07 G" + [2,] "6e-07 G" "6e-07 G" "6e-07 G" [3,] "8e-04 G" "8e-04 G" "8e-04 G" - [4,] "7e-01 G" "7e-01 G" "7e-01 G" - [5,] "7e+02 G" "7e+02 G" "7e+02 G" + [4,] "4e-01 G" "4e-01 G" "4e-01 G" + [5,] "3e+02 G" "3e+02 G" "3e+02 G" [6,] "4e+05 G" "4e+05 G" "4e+05 G" - [7,] "6e+08 G" "6e+08 G" "6e+08 G" + [7,] "5e+08 G" "5e+08 G" "5e+08 G" [8,] "8e+11 G" "8e+11 G" "8e+11 G" - [9,] "8e+14 G" "8e+14 G" "8e+14 G" + [9,] "9e+14 G" "9e+14 G" "9e+14 G" [10,] "9e+17 G" "9e+17 G" "9e+17 G" > > # Single unit, specify digits @@ -176,37 +178,37 @@ + ) [,1] [,2] [,3] [,4] [1,] "5.000000e-10 GB" "5.00e-10 GB" "5.0e-10 GB" "5e-10 GB" - [2,] "7.414207e-07 GB" "7.41e-07 GB" "7.4e-07 GB" "7e-07 GB" - [3,] "7.460970e-04 GB" "7.46e-04 GB" "7.5e-04 GB" "7e-04 GB" - [4,] "3.990084e-01 GB" "3.99e-01 GB" "4.0e-01 GB" "4e-01 GB" - [5,] "7.334410e+02 GB" "7.33e+02 GB" "7.3e+02 GB" "7e+02 GB" - [6,] "6.745084e+05 GB" "6.75e+05 GB" "6.7e+05 GB" "7e+05 GB" - [7,] "7.885941e+08 GB" "7.89e+08 GB" "7.9e+08 GB" "8e+08 GB" - [8,] "7.496193e+11 GB" "7.50e+11 GB" "7.5e+11 GB" "7e+11 GB" - [9,] "3.579472e+14 GB" "3.58e+14 GB" "3.6e+14 GB" "4e+14 GB" -[10,] "7.498742e+17 GB" "7.50e+17 GB" "7.5e+17 GB" "7e+17 GB" + [2,] "7.993163e-07 GB" "7.99e-07 GB" "8.0e-07 GB" "8e-07 GB" + [3,] "7.900375e-04 GB" "7.90e-04 GB" "7.9e-04 GB" "8e-04 GB" + [4,] "6.619855e-01 GB" "6.62e-01 GB" "6.6e-01 GB" "7e-01 GB" + [5,] "6.311259e+02 GB" "6.31e+02 GB" "6.3e+02 GB" "6e+02 GB" + [6,] "6.440324e+05 GB" "6.44e+05 GB" "6.4e+05 GB" "6e+05 GB" + [7,] "4.994386e+08 GB" "4.99e+08 GB" "5.0e+08 GB" "5e+08 GB" + [8,] "7.277869e+11 GB" "7.28e+11 GB" "7.3e+11 GB" "7e+11 GB" + [9,] "3.291745e+14 GB" "3.29e+14 GB" "3.3e+14 GB" "3e+14 GB" +[10,] "8.313511e+17 GB" "8.31e+17 GB" "8.3e+17 GB" "8e+17 GB" [,5] [,6] [,7] [,8] [1,] "4.656613e-10 GiB" "4.66e-10 GiB" "4.7e-10 GiB" "5e-10 GiB" - [2,] "7.237764e-07 GiB" "7.24e-07 GiB" "7.2e-07 GiB" "7e-07 GiB" - [3,] "7.979097e-04 GiB" "7.98e-04 GiB" "8.0e-04 GiB" "8e-04 GiB" - [4,] "6.742969e-01 GiB" "6.74e-01 GiB" "6.7e-01 GiB" "7e-01 GiB" - [5,] "7.149879e+02 GiB" "7.15e+02 GiB" "7.1e+02 GiB" "7e+02 GiB" - [6,] "4.269769e+05 GiB" "4.27e+05 GiB" "4.3e+05 GiB" "4e+05 GiB" - [7,] "6.355649e+08 GiB" "6.36e+08 GiB" "6.4e+08 GiB" "6e+08 GiB" - [8,] "7.956378e+11 GiB" "7.96e+11 GiB" "8.0e+11 GiB" "8e+11 GiB" - [9,] "7.665900e+14 GiB" "7.67e+14 GiB" "7.7e+14 GiB" "8e+14 GiB" -[10,] "8.561693e+17 GiB" "8.56e+17 GiB" "8.6e+17 GiB" "9e+17 GiB" + [2,] "5.975956e-07 GiB" "5.98e-07 GiB" "6.0e-07 GiB" "6e-07 GiB" + [3,] "7.764672e-04 GiB" "7.76e-04 GiB" "7.8e-04 GiB" "8e-04 GiB" + [4,] "4.459146e-01 GiB" "4.46e-01 GiB" "4.5e-01 GiB" "4e-01 GiB" + [5,] "2.985889e+02 GiB" "2.99e+02 GiB" "3.0e+02 GiB" "3e+02 GiB" + [6,] "4.209112e+05 GiB" "4.21e+05 GiB" "4.2e+05 GiB" "4e+05 GiB" + [7,] "4.983449e+08 GiB" "4.98e+08 GiB" "5.0e+08 GiB" "5e+08 GiB" + [8,] "7.751081e+11 GiB" "7.75e+11 GiB" "7.8e+11 GiB" "8e+11 GiB" + [9,] "8.756173e+14 GiB" "8.76e+14 GiB" "8.8e+14 GiB" "9e+14 GiB" +[10,] "9.390947e+17 GiB" "9.39e+17 GiB" "9.4e+17 GiB" "9e+17 GiB" [,9] [,10] [,11] [,12] [1,] "4.656613e-10 G" "4.66e-10 G" "4.7e-10 G" "5e-10 G" - [2,] "7.237764e-07 G" "7.24e-07 G" "7.2e-07 G" "7e-07 G" - [3,] "7.979097e-04 G" "7.98e-04 G" "8.0e-04 G" "8e-04 G" - [4,] "6.742969e-01 G" "6.74e-01 G" "6.7e-01 G" "7e-01 G" - [5,] "7.149879e+02 G" "7.15e+02 G" "7.1e+02 G" "7e+02 G" - [6,] "4.269769e+05 G" "4.27e+05 G" "4.3e+05 G" "4e+05 G" - [7,] "6.355649e+08 G" "6.36e+08 G" "6.4e+08 G" "6e+08 G" - [8,] "7.956378e+11 G" "7.96e+11 G" "8.0e+11 G" "8e+11 G" - [9,] "7.665900e+14 G" "7.67e+14 G" "7.7e+14 G" "8e+14 G" -[10,] "8.561693e+17 G" "8.56e+17 G" "8.6e+17 G" "9e+17 G" + [2,] "5.975956e-07 G" "5.98e-07 G" "6.0e-07 G" "6e-07 G" + [3,] "7.764672e-04 G" "7.76e-04 G" "7.8e-04 G" "8e-04 G" + [4,] "4.459146e-01 G" "4.46e-01 G" "4.5e-01 G" "4e-01 G" + [5,] "2.985889e+02 G" "2.99e+02 G" "3.0e+02 G" "3e+02 G" + [6,] "4.209112e+05 G" "4.21e+05 G" "4.2e+05 G" "4e+05 G" + [7,] "4.983449e+08 G" "4.98e+08 G" "5.0e+08 G" "5e+08 G" + [8,] "7.751081e+11 G" "7.75e+11 G" "7.8e+11 G" "8e+11 G" + [9,] "8.756173e+14 G" "8.76e+14 G" "8.8e+14 G" "9e+14 G" +[10,] "9.390947e+17 G" "9.39e+17 G" "9.4e+17 G" "9e+17 G" > > > stopifnot( is.object_sizes(as.object_sizes( 2^(1:30) ) ) ) @@ -233,4 +235,4 @@ > > proc.time() user system elapsed - 0.427 0.050 0.472 + 0.410 0.050 0.451 Modified: trunk/gdata/tests/test.read.xls.Rout.save =================================================================== --- trunk/gdata/tests/test.read.xls.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) +++ trunk/gdata/tests/test.read.xls.Rout.save 2015-04-25 16:46:12 UTC (rev 1969) @@ -846,4 +846,4 @@ > > proc.time() user system elapsed - 14.409 0.863 15.497 + 14.104 0.888 15.221 Modified: trunk/gdata/tests/test.reorder.factor.Rout.save =================================================================== --- trunk/gdata/tests/test.reorder.factor.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) +++ trunk/gdata/tests/test.reorder.factor.Rout.save 2015-04-25 16:46:12 UTC (rev 1969) @@ -53,4 +53,4 @@ > > proc.time() user system elapsed - 0.357 0.048 0.401 + 0.339 0.046 0.379 Modified: trunk/gdata/tests/tests.write.fwf.Rout.save =================================================================== --- trunk/gdata/tests/tests.write.fwf.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) +++ trunk/gdata/tests/tests.write.fwf.Rout.save 2015-04-25 16:46:12 UTC (rev 1969) @@ -231,4 +231,4 @@ > > proc.time() user system elapsed - 0.476 0.053 0.524 + 0.434 0.049 0.475 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 16:37:08
|
Revision: 1968 http://sourceforge.net/p/r-gregmisc/code/1968 Author: warnes Date: 2015-04-25 16:37:00 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Update .save files Modified Paths: -------------- trunk/gdata/tests/test.humanReadable.Rout.save trunk/gdata/tests/test.read.xls.Rout.save trunk/gdata/tests/test.reorder.factor.Rout.save trunk/gdata/tests/tests.write.fwf.Rout.save Modified: trunk/gdata/tests/test.humanReadable.Rout.save =================================================================== --- trunk/gdata/tests/test.humanReadable.Rout.save 2015-04-25 16:24:41 UTC (rev 1967) +++ trunk/gdata/tests/test.humanReadable.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) @@ -18,13 +18,8 @@ > library(gdata) gdata: read.xls support for 'XLS' (Excel 97-2004) files ENABLED. -gdata: Unable to load perl libaries needed by read.xls() -gdata: to support 'XLSX' (Excel 2007+) files. +gdata: read.xls support for 'XLSX' (Excel 2007+) files ENABLED. -gdata: Run the function 'installXLSXsupport()' -gdata: to automatically download and install the perl -gdata: libaries needed to support Excel XLS and XLSX formats. - Attaching package: 'gdata' The following object is masked from 'package:stats': @@ -63,26 +58,26 @@ + humanReadable(x=IEC2, standard="Unix", width=3)) [,1] [,2] [,3] [,4] [,5] [,6] [1,] " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " - [2,] "1.19855 kB" "1.199 kB" " 1.2 kB" "1.23404 KiB" "1.234 KiB" " 1.2 KiB" - [3,] "1.20686 MB" "1.207 MB" " 1.2 MB" "1.24529 MiB" "1.245 MiB" " 1.2 MiB" - [4,] "1.24218 GB" "1.242 GB" " 1.2 GB" "1.19621 GiB" "1.196 GiB" " 1.2 GiB" - [5,] "1.20157 TB" "1.202 TB" " 1.2 TB" "1.21737 TiB" "1.217 TiB" " 1.2 TiB" - [6,] "1.26255 PB" "1.263 PB" " 1.3 PB" "1.57268 PiB" "1.573 PiB" " 1.6 PiB" - [7,] "1.35911 EB" "1.359 EB" " 1.4 EB" "1.18177 EiB" "1.182 EiB" " 1.2 EiB" - [8,] " 1.2033 ZB" "1.203 ZB" " 1.2 ZB" "1.49049 ZiB" " 1.49 ZiB" " 1.5 ZiB" - [9,] "1.35332 YB" "1.353 YB" " 1.4 YB" "1.84401 YiB" "1.844 YiB" " 1.8 YiB" -[10,] " 1723.7 YB" " 1724 YB" "1724 YB" "1216.27 YiB" " 1216 YiB" "1216 YiB" + [2,] " 1.2793 kB" "1.279 kB" " 1.3 kB" " 1.2233 KiB" "1.223 KiB" " 1.2 KiB" + [3,] "1.20319 MB" "1.203 MB" " 1.2 MB" "1.29885 MiB" "1.299 MiB" " 1.3 MiB" + [4,] "1.16832 GB" "1.168 GB" " 1.2 GB" "1.22854 GiB" "1.229 GiB" " 1.2 GiB" + [5,] "1.68539 TB" "1.685 TB" " 1.7 TB" "1.49459 TiB" "1.495 TiB" " 1.5 TiB" + [6,] "1.20409 PB" "1.204 PB" " 1.2 PB" "1.30007 PiB" " 1.3 PiB" " 1.3 PiB" + [7,] " 1.4313 EB" "1.431 EB" " 1.4 EB" " 1.3716 EiB" "1.372 EiB" " 1.4 EiB" + [8,] "1.19649 ZB" "1.196 ZB" " 1.2 ZB" "1.26321 ZiB" "1.263 ZiB" " 1.3 ZiB" + [9,] "1.17615 YB" "1.176 YB" " 1.2 YB" "1.30608 YiB" "1.306 YiB" " 1.3 YiB" +[10,] "1270.14 YB" " 1270 YB" "1270 YB" " 1373.7 YiB" " 1374 YiB" "1374 YiB" [,7] [,8] [,9] [1,] " 2 B" " 2 B" " 2 B" - [2,] "1.23404 K" "1.234 K" " 1.2 K" - [3,] "1.24529 M" "1.245 M" " 1.2 M" - [4,] "1.19621 G" "1.196 G" " 1.2 G" - [5,] "1.21737 T" "1.217 T" " 1.2 T" - [6,] "1.57268 P" "1.573 P" " 1.6 P" - [7,] "1.18177 E" "1.182 E" " 1.2 E" - [8,] "1.49049 Z" " 1.49 Z" " 1.5 Z" - [9,] "1.84401 Y" "1.844 Y" " 1.8 Y" -[10,] "1216.27 Y" " 1216 Y" "1216 Y" + [2,] " 1.2233 K" "1.223 K" " 1.2 K" + [3,] "1.29885 M" "1.299 M" " 1.3 M" + [4,] "1.22854 G" "1.229 G" " 1.2 G" + [5,] "1.49459 T" "1.495 T" " 1.5 T" + [6,] "1.30007 P" " 1.3 P" " 1.3 P" + [7,] " 1.3716 E" "1.372 E" " 1.4 E" + [8,] "1.26321 Z" "1.263 Z" " 1.3 Z" + [9,] "1.30608 Y" "1.306 Y" " 1.3 Y" +[10,] " 1373.7 Y" " 1374 Y" "1374 Y" > > # Auto units, specify digits > cbind(humanReadable(x=SI2, standard="SI", width=NULL, digits=7), @@ -99,37 +94,37 @@ + humanReadable(x=IEC2, standard="Unix", width=NULL, digits=1)) [,1] [,2] [,3] [,4] [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " - [2,] " 1.1985486 kB" " 1.199 kB" " 1.20 kB" " 1.2 kB" - [3,] " 1.2068563 MB" " 1.207 MB" " 1.21 MB" " 1.2 MB" - [4,] " 1.2421751 GB" " 1.242 GB" " 1.24 GB" " 1.2 GB" - [5,] " 1.2015680 TB" " 1.202 TB" " 1.20 TB" " 1.2 TB" - [6,] " 1.2625549 PB" " 1.263 PB" " 1.26 PB" " 1.3 PB" - [7,] " 1.3591145 EB" " 1.359 EB" " 1.36 EB" " 1.4 EB" - [8,] " 1.2033002 ZB" " 1.203 ZB" " 1.20 ZB" " 1.2 ZB" - [9,] " 1.3533151 YB" " 1.353 YB" " 1.35 YB" " 1.4 YB" -[10,] "1723.7026620 YB" "1723.703 YB" "1723.70 YB" "1723.7 YB" + [2,] " 1.2793050 kB" " 1.279 kB" " 1.28 kB" " 1.3 kB" + [3,] " 1.2031896 MB" " 1.203 MB" " 1.20 MB" " 1.2 MB" + [4,] " 1.1683216 GB" " 1.168 GB" " 1.17 GB" " 1.2 GB" + [5,] " 1.6853920 TB" " 1.685 TB" " 1.69 TB" " 1.7 TB" + [6,] " 1.2040855 PB" " 1.204 PB" " 1.20 PB" " 1.2 PB" + [7,] " 1.4313005 EB" " 1.431 EB" " 1.43 EB" " 1.4 EB" + [8,] " 1.1964931 ZB" " 1.196 ZB" " 1.20 ZB" " 1.2 ZB" + [9,] " 1.1761521 YB" " 1.176 YB" " 1.18 YB" " 1.2 YB" +[10,] "1270.1414519 YB" "1270.141 YB" "1270.14 YB" "1270.1 YB" [,5] [,6] [,7] [,8] [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " - [2,] " 1.2340441 KiB" " 1.234 KiB" " 1.23 KiB" " 1.2 KiB" - [3,] " 1.2452876 MiB" " 1.245 MiB" " 1.25 MiB" " 1.2 MiB" - [4,] " 1.1962114 GiB" " 1.196 GiB" " 1.20 GiB" " 1.2 GiB" - [5,] " 1.2173697 TiB" " 1.217 TiB" " 1.22 TiB" " 1.2 TiB" - [6,] " 1.5726781 PiB" " 1.573 PiB" " 1.57 PiB" " 1.6 PiB" - [7,] " 1.1817693 EiB" " 1.182 EiB" " 1.18 EiB" " 1.2 EiB" - [8,] " 1.4904906 ZiB" " 1.490 ZiB" " 1.49 ZiB" " 1.5 ZiB" - [9,] " 1.8440055 YiB" " 1.844 YiB" " 1.84 YiB" " 1.8 YiB" -[10,] "1216.2741325 YiB" "1216.274 YiB" "1216.27 YiB" "1216.3 YiB" + [2,] " 1.2232984 KiB" " 1.223 KiB" " 1.22 KiB" " 1.2 KiB" + [3,] " 1.2988465 MiB" " 1.299 MiB" " 1.30 MiB" " 1.3 MiB" + [4,] " 1.2285433 GiB" " 1.229 GiB" " 1.23 GiB" " 1.2 GiB" + [5,] " 1.4945944 TiB" " 1.495 TiB" " 1.49 TiB" " 1.5 TiB" + [6,] " 1.3000707 PiB" " 1.300 PiB" " 1.30 PiB" " 1.3 PiB" + [7,] " 1.3716001 EiB" " 1.372 EiB" " 1.37 EiB" " 1.4 EiB" + [8,] " 1.2632150 ZiB" " 1.263 ZiB" " 1.26 ZiB" " 1.3 ZiB" + [9,] " 1.3060808 YiB" " 1.306 YiB" " 1.31 YiB" " 1.3 YiB" +[10,] "1373.6975294 YiB" "1373.698 YiB" "1373.70 YiB" "1373.7 YiB" [,9] [,10] [,11] [,12] [1,] " 1.5000000 B" " 1.500 B" " 1.50 B" " 1.5 B" - [2,] " 1.2340441 K" " 1.234 K" " 1.23 K" " 1.2 K" - [3,] " 1.2452876 M" " 1.245 M" " 1.25 M" " 1.2 M" - [4,] " 1.1962114 G" " 1.196 G" " 1.20 G" " 1.2 G" - [5,] " 1.2173697 T" " 1.217 T" " 1.22 T" " 1.2 T" - [6,] " 1.5726781 P" " 1.573 P" " 1.57 P" " 1.6 P" - [7,] " 1.1817693 E" " 1.182 E" " 1.18 E" " 1.2 E" - [8,] " 1.4904906 Z" " 1.490 Z" " 1.49 Z" " 1.5 Z" - [9,] " 1.8440055 Y" " 1.844 Y" " 1.84 Y" " 1.8 Y" -[10,] "1216.2741325 Y" "1216.274 Y" "1216.27 Y" "1216.3 Y" + [2,] " 1.2232984 K" " 1.223 K" " 1.22 K" " 1.2 K" + [3,] " 1.2988465 M" " 1.299 M" " 1.30 M" " 1.3 M" + [4,] " 1.2285433 G" " 1.229 G" " 1.23 G" " 1.2 G" + [5,] " 1.4945944 T" " 1.495 T" " 1.49 T" " 1.5 T" + [6,] " 1.3000707 P" " 1.300 P" " 1.30 P" " 1.3 P" + [7,] " 1.3716001 E" " 1.372 E" " 1.37 E" " 1.4 E" + [8,] " 1.2632150 Z" " 1.263 Z" " 1.26 Z" " 1.3 Z" + [9,] " 1.3060808 Y" " 1.306 Y" " 1.31 Y" " 1.3 Y" +[10,] "1373.6975294 Y" "1373.698 Y" "1373.70 Y" "1373.7 Y" > > # Single unit, specify width > cbind(humanReadable(x=SI1, units="GB", standard="SI", width=7), @@ -144,26 +139,26 @@ + ) [,1] [,2] [,3] [,4] [,5] [,6] [1,] "5e-10 GB" "5e-10 GB" "5e-10 GB" "5e-10 GiB" "5e-10 GiB" "5e-10 GiB" - [2,] "8e-07 GB" "8e-07 GB" "8e-07 GB" "7e-07 GiB" "7e-07 GiB" "7e-07 GiB" - [3,] "8e-04 GB" "8e-04 GB" "8e-04 GB" "8e-04 GiB" "8e-04 GiB" "8e-04 GiB" - [4,] "8e-01 GB" "8e-01 GB" "8e-01 GB" "8e-01 GiB" "8e-01 GiB" "8e-01 GiB" - [5,] "8e+02 GB" "8e+02 GB" "8e+02 GB" "6e+02 GiB" "6e+02 GiB" "6e+02 GiB" - [6,] "8e+05 GB" "8e+05 GB" "8e+05 GB" "6e+05 GiB" "6e+05 GiB" "6e+05 GiB" - [7,] "8e+08 GB" "8e+08 GB" "8e+08 GB" "8e+08 GiB" "8e+08 GiB" "8e+08 GiB" - [8,] "8e+11 GB" "8e+11 GB" "8e+11 GB" "9e+11 GiB" "9e+11 GiB" "9e+11 GiB" - [9,] "8e+14 GB" "8e+14 GB" "8e+14 GB" "4e+14 GiB" "4e+14 GiB" "4e+14 GiB" -[10,] "7e+17 GB" "7e+17 GB" "7e+17 GB" "8e+17 GiB" "8e+17 GiB" "8e+17 GiB" + [2,] "7e-07 GB" "7e-07 GB" "7e-07 GB" "7e-07 GiB" "7e-07 GiB" "7e-07 GiB" + [3,] "7e-04 GB" "7e-04 GB" "7e-04 GB" "8e-04 GiB" "8e-04 GiB" "8e-04 GiB" + [4,] "4e-01 GB" "4e-01 GB" "4e-01 GB" "7e-01 GiB" "7e-01 GiB" "7e-01 GiB" + [5,] "7e+02 GB" "7e+02 GB" "7e+02 GB" "7e+02 GiB" "7e+02 GiB" "7e+02 GiB" + [6,] "7e+05 GB" "7e+05 GB" "7e+05 GB" "4e+05 GiB" "4e+05 GiB" "4e+05 GiB" + [7,] "8e+08 GB" "8e+08 GB" "8e+08 GB" "6e+08 GiB" "6e+08 GiB" "6e+08 GiB" + [8,] "7e+11 GB" "7e+11 GB" "7e+11 GB" "8e+11 GiB" "8e+11 GiB" "8e+11 GiB" + [9,] "4e+14 GB" "4e+14 GB" "4e+14 GB" "8e+14 GiB" "8e+14 GiB" "8e+14 GiB" +[10,] "7e+17 GB" "7e+17 GB" "7e+17 GB" "9e+17 GiB" "9e+17 GiB" "9e+17 GiB" [,7] [,8] [,9] [1,] "5e-10 G" "5e-10 G" "5e-10 G" [2,] "7e-07 G" "7e-07 G" "7e-07 G" [3,] "8e-04 G" "8e-04 G" "8e-04 G" - [4,] "8e-01 G" "8e-01 G" "8e-01 G" - [5,] "6e+02 G" "6e+02 G" "6e+02 G" - [6,] "6e+05 G" "6e+05 G" "6e+05 G" - [7,] "8e+08 G" "8e+08 G" "8e+08 G" - [8,] "9e+11 G" "9e+11 G" "9e+11 G" - [9,] "4e+14 G" "4e+14 G" "4e+14 G" -[10,] "8e+17 G" "8e+17 G" "8e+17 G" + [4,] "7e-01 G" "7e-01 G" "7e-01 G" + [5,] "7e+02 G" "7e+02 G" "7e+02 G" + [6,] "4e+05 G" "4e+05 G" "4e+05 G" + [7,] "6e+08 G" "6e+08 G" "6e+08 G" + [8,] "8e+11 G" "8e+11 G" "8e+11 G" + [9,] "8e+14 G" "8e+14 G" "8e+14 G" +[10,] "9e+17 G" "9e+17 G" "9e+17 G" > > # Single unit, specify digits > cbind(humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=7), @@ -181,37 +176,37 @@ + ) [,1] [,2] [,3] [,4] [1,] "5.000000e-10 GB" "5.00e-10 GB" "5.0e-10 GB" "5e-10 GB" - [2,] "7.792994e-07 GB" "7.79e-07 GB" "7.8e-07 GB" "8e-07 GB" - [3,] "7.796269e-04 GB" "7.80e-04 GB" "7.8e-04 GB" "8e-04 GB" - [4,] "8.033561e-01 GB" "8.03e-01 GB" "8.0e-01 GB" "8e-01 GB" - [5,] "8.314840e+02 GB" "8.31e+02 GB" "8.3e+02 GB" "8e+02 GB" - [6,] "8.018065e+05 GB" "8.02e+05 GB" "8.0e+05 GB" "8e+05 GB" - [7,] "8.032533e+08 GB" "8.03e+08 GB" "8.0e+08 GB" "8e+08 GB" - [8,] "7.736007e+11 GB" "7.74e+11 GB" "7.7e+11 GB" "8e+11 GB" - [9,] "8.033881e+14 GB" "8.03e+14 GB" "8.0e+14 GB" "8e+14 GB" -[10,] "6.856332e+17 GB" "6.86e+17 GB" "6.9e+17 GB" "7e+17 GB" + [2,] "7.414207e-07 GB" "7.41e-07 GB" "7.4e-07 GB" "7e-07 GB" + [3,] "7.460970e-04 GB" "7.46e-04 GB" "7.5e-04 GB" "7e-04 GB" + [4,] "3.990084e-01 GB" "3.99e-01 GB" "4.0e-01 GB" "4e-01 GB" + [5,] "7.334410e+02 GB" "7.33e+02 GB" "7.3e+02 GB" "7e+02 GB" + [6,] "6.745084e+05 GB" "6.75e+05 GB" "6.7e+05 GB" "7e+05 GB" + [7,] "7.885941e+08 GB" "7.89e+08 GB" "7.9e+08 GB" "8e+08 GB" + [8,] "7.496193e+11 GB" "7.50e+11 GB" "7.5e+11 GB" "7e+11 GB" + [9,] "3.579472e+14 GB" "3.58e+14 GB" "3.6e+14 GB" "4e+14 GB" +[10,] "7.498742e+17 GB" "7.50e+17 GB" "7.5e+17 GB" "7e+17 GB" [,5] [,6] [,7] [,8] [1,] "4.656613e-10 GiB" "4.66e-10 GiB" "4.7e-10 GiB" "5e-10 GiB" - [2,] "7.138398e-07 GiB" "7.14e-07 GiB" "7.1e-07 GiB" "7e-07 GiB" - [3,] "7.600841e-04 GiB" "7.60e-04 GiB" "7.6e-04 GiB" "8e-04 GiB" - [4,] "8.231780e-01 GiB" "8.23e-01 GiB" "8.2e-01 GiB" "8e-01 GiB" - [5,] "5.678312e+02 GiB" "5.68e+02 GiB" "5.7e+02 GiB" "6e+02 GiB" - [6,] "5.506880e+05 GiB" "5.51e+05 GiB" "5.5e+05 GiB" "6e+05 GiB" - [7,] "8.221636e+08 GiB" "8.22e+08 GiB" "8.2e+08 GiB" "8e+08 GiB" - [8,] "8.721612e+11 GiB" "8.72e+11 GiB" "8.7e+11 GiB" "9e+11 GiB" - [9,] "4.356026e+14 GiB" "4.36e+14 GiB" "4.4e+14 GiB" "4e+14 GiB" -[10,] "8.080586e+17 GiB" "8.08e+17 GiB" "8.1e+17 GiB" "8e+17 GiB" + [2,] "7.237764e-07 GiB" "7.24e-07 GiB" "7.2e-07 GiB" "7e-07 GiB" + [3,] "7.979097e-04 GiB" "7.98e-04 GiB" "8.0e-04 GiB" "8e-04 GiB" + [4,] "6.742969e-01 GiB" "6.74e-01 GiB" "6.7e-01 GiB" "7e-01 GiB" + [5,] "7.149879e+02 GiB" "7.15e+02 GiB" "7.1e+02 GiB" "7e+02 GiB" + [6,] "4.269769e+05 GiB" "4.27e+05 GiB" "4.3e+05 GiB" "4e+05 GiB" + [7,] "6.355649e+08 GiB" "6.36e+08 GiB" "6.4e+08 GiB" "6e+08 GiB" + [8,] "7.956378e+11 GiB" "7.96e+11 GiB" "8.0e+11 GiB" "8e+11 GiB" + [9,] "7.665900e+14 GiB" "7.67e+14 GiB" "7.7e+14 GiB" "8e+14 GiB" +[10,] "8.561693e+17 GiB" "8.56e+17 GiB" "8.6e+17 GiB" "9e+17 GiB" [,9] [,10] [,11] [,12] [1,] "4.656613e-10 G" "4.66e-10 G" "4.7e-10 G" "5e-10 G" - [2,] "7.138398e-07 G" "7.14e-07 G" "7.1e-07 G" "7e-07 G" - [3,] "7.600841e-04 G" "7.60e-04 G" "7.6e-04 G" "8e-04 G" - [4,] "8.231780e-01 G" "8.23e-01 G" "8.2e-01 G" "8e-01 G" - [5,] "5.678312e+02 G" "5.68e+02 G" "5.7e+02 G" "6e+02 G" - [6,] "5.506880e+05 G" "5.51e+05 G" "5.5e+05 G" "6e+05 G" - [7,] "8.221636e+08 G" "8.22e+08 G" "8.2e+08 G" "8e+08 G" - [8,] "8.721612e+11 G" "8.72e+11 G" "8.7e+11 G" "9e+11 G" - [9,] "4.356026e+14 G" "4.36e+14 G" "4.4e+14 G" "4e+14 G" -[10,] "8.080586e+17 G" "8.08e+17 G" "8.1e+17 G" "8e+17 G" + [2,] "7.237764e-07 G" "7.24e-07 G" "7.2e-07 G" "7e-07 G" + [3,] "7.979097e-04 G" "7.98e-04 G" "8.0e-04 G" "8e-04 G" + [4,] "6.742969e-01 G" "6.74e-01 G" "6.7e-01 G" "7e-01 G" + [5,] "7.149879e+02 G" "7.15e+02 G" "7.1e+02 G" "7e+02 G" + [6,] "4.269769e+05 G" "4.27e+05 G" "4.3e+05 G" "4e+05 G" + [7,] "6.355649e+08 G" "6.36e+08 G" "6.4e+08 G" "6e+08 G" + [8,] "7.956378e+11 G" "7.96e+11 G" "8.0e+11 G" "8e+11 G" + [9,] "7.665900e+14 G" "7.67e+14 G" "7.7e+14 G" "8e+14 G" +[10,] "8.561693e+17 G" "8.56e+17 G" "8.6e+17 G" "9e+17 G" > > > stopifnot( is.object_sizes(as.object_sizes( 2^(1:30) ) ) ) @@ -238,4 +233,4 @@ > > proc.time() user system elapsed - 0.368 0.047 0.415 + 0.427 0.050 0.472 Modified: trunk/gdata/tests/test.read.xls.Rout.save =================================================================== --- trunk/gdata/tests/test.read.xls.Rout.save 2015-04-25 16:24:41 UTC (rev 1967) +++ trunk/gdata/tests/test.read.xls.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) @@ -1,7 +1,7 @@ -R version 3.1.0 Patched (2014-05-26 r65771) -- "Spring Dance" -Copyright (C) 2014 The R Foundation for Statistical Computing -Platform: x86_64-apple-darwin13.1.0 (64-bit) +R version 3.2.0 (2015-04-16) -- "Full of Ingredients" +Copyright (C) 2015 The R Foundation for Statistical Computing +Platform: x86_64-apple-darwin13.4.0 (64-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. @@ -846,4 +846,4 @@ > > proc.time() user system elapsed - 12.406 0.727 13.299 + 14.409 0.863 15.497 Modified: trunk/gdata/tests/test.reorder.factor.Rout.save =================================================================== --- trunk/gdata/tests/test.reorder.factor.Rout.save 2015-04-25 16:24:41 UTC (rev 1967) +++ trunk/gdata/tests/test.reorder.factor.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) @@ -29,13 +29,8 @@ > library(gdata) gdata: read.xls support for 'XLS' (Excel 97-2004) files ENABLED. -gdata: Unable to load perl libaries needed by read.xls() -gdata: to support 'XLSX' (Excel 2007+) files. +gdata: read.xls support for 'XLSX' (Excel 2007+) files ENABLED. -gdata: Run the function 'installXLSXsupport()' -gdata: to automatically download and install the perl -gdata: libaries needed to support Excel XLS and XLSX formats. - Attaching package: 'gdata' The following object is masked from 'package:stats': @@ -58,4 +53,4 @@ > > proc.time() user system elapsed - 0.300 0.049 0.345 + 0.357 0.048 0.401 Modified: trunk/gdata/tests/tests.write.fwf.Rout.save =================================================================== --- trunk/gdata/tests/tests.write.fwf.Rout.save 2015-04-25 16:24:41 UTC (rev 1967) +++ trunk/gdata/tests/tests.write.fwf.Rout.save 2015-04-25 16:37:00 UTC (rev 1968) @@ -25,13 +25,8 @@ > library(gdata) gdata: read.xls support for 'XLS' (Excel 97-2004) files ENABLED. -gdata: Unable to load perl libaries needed by read.xls() -gdata: to support 'XLSX' (Excel 2007+) files. +gdata: read.xls support for 'XLSX' (Excel 2007+) files ENABLED. -gdata: Run the function 'installXLSXsupport()' -gdata: to automatically download and install the perl -gdata: libaries needed to support Excel XLS and XLSX formats. - Attaching package: 'gdata' The following object is masked from 'package:stats': @@ -85,7 +80,7 @@ > ## NA should be - > write.fwf(x=testData, na="-") num1 num2 num3 int1 fac1 fac2 cha1 cha2 Date POSIXt - 1 - - 1 - f q - 1900-01-01 1900-01-01 01:01:01 + 1 - - 1 - f q - 1900-01-01 1900-01-01 01:01:01 2 1.0 733070.3 2 a g r longer - 1900-01-01 01:01:01 3 1.5 1214213.8 3 b h s y 1900-01-01 1900-01-01 01:01:01 4 2.0 553823.8 4 c i t x 1900-01-01 1900-01-01 01:01:01 @@ -95,21 +90,21 @@ 8 4.0 1053686.6 6 g m x t 1900-01-01 1900-01-01 01:01:01 9 4.5 971024.2 7 h n y s 1900-01-01 1900-01-01 01:01:01 10 5.0 631193.4 8 i o z r 1900-01-01 1900-01-01 01:01:01 -- 5.5 879431.1 9 hjh - - q 1900-01-01 1900-01-01 01:01:01 + - 5.5 879431.1 9 hjh - - q 1900-01-01 1900-01-01 01:01:01 > ## NA should be -NA- > write.fwf(x=testData, na="-NA-") num1 num2 num3 int1 fac1 fac2 cha1 cha2 Date POSIXt - 1 -NA- -NA- 1 -NA- f q -NA- 1900-01-01 1900-01-01 01:01:01 - 2 1.0 733070.3 2 a g r longer -NA- 1900-01-01 01:01:01 - 3 1.5 1214213.8 3 b h s y 1900-01-01 1900-01-01 01:01:01 - 4 2.0 553823.8 4 c i t x 1900-01-01 1900-01-01 01:01:01 - 5 2.5 1085022.9 -NA- d j u w 1900-01-01 -NA- - 6 3.0 571063.9 4 e k v v 1900-01-01 1900-01-01 01:01:01 - 7 3.5 606718.4 5 f l w u 1900-01-01 1900-01-01 01:01:01 - 8 4.0 1053686.6 6 g m x t 1900-01-01 1900-01-01 01:01:01 - 9 4.5 971024.2 7 h n y s 1900-01-01 1900-01-01 01:01:01 -10 5.0 631193.4 8 i o z r 1900-01-01 1900-01-01 01:01:01 --NA- 5.5 879431.1 9 hjh -NA- -NA- q 1900-01-01 1900-01-01 01:01:01 + 1 -NA- -NA- 1 -NA- f q -NA- 1900-01-01 1900-01-01 01:01:01 + 2 1.0 733070.3 2 a g r longer -NA- 1900-01-01 01:01:01 + 3 1.5 1214213.8 3 b h s y 1900-01-01 1900-01-01 01:01:01 + 4 2.0 553823.8 4 c i t x 1900-01-01 1900-01-01 01:01:01 + 5 2.5 1085022.9 -NA- d j u w 1900-01-01 -NA- + 6 3.0 571063.9 4 e k v v 1900-01-01 1900-01-01 01:01:01 + 7 3.5 606718.4 5 f l w u 1900-01-01 1900-01-01 01:01:01 + 8 4.0 1053686.6 6 g m x t 1900-01-01 1900-01-01 01:01:01 + 9 4.5 971024.2 7 h n y s 1900-01-01 1900-01-01 01:01:01 + 10 5.0 631193.4 8 i o z r 1900-01-01 1900-01-01 01:01:01 +-NA- 5.5 879431.1 9 hjh -NA- -NA- q 1900-01-01 1900-01-01 01:01:01 > > ## Some other separator than space > write.fwf(testData[, 1:4], sep="-mySep-") @@ -236,4 +231,4 @@ > > proc.time() user system elapsed - 0.413 0.044 0.448 + 0.476 0.053 0.524 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 16:24:43
|
Revision: 1967 http://sourceforge.net/p/r-gregmisc/code/1967 Author: warnes Date: 2015-04-25 16:24:41 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Missed on commit. Modified Paths: -------------- trunk/gdata/R/write.fwf.R Modified: trunk/gdata/R/write.fwf.R =================================================================== --- trunk/gdata/R/write.fwf.R 2015-04-25 16:23:31 UTC (rev 1966) +++ trunk/gdata/R/write.fwf.R 2015-04-25 16:24:41 UTC (rev 1967) @@ -49,7 +49,8 @@ if(rownames) { - x <- cbind(rownames(x), as.data.frame(x)) + x <- as.data.frame(x) + x <- cbind(rownames(x), x) rowColVal <- ifelse(!is.null(rowCol), rowCol, "row") colnames(x)[1] <- rowColVal } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 16:23:33
|
Revision: 1966 http://sourceforge.net/p/r-gregmisc/code/1966 Author: warnes Date: 2015-04-25 16:23:31 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Modfy write.fwf() to properly handle matrix argument, avoiding conversion to dataframe unless rownames=TRUE. Add corresponding unit tests. Modified Paths: -------------- trunk/gdata/R/write.fwf.R trunk/gdata/tests/test.humanReadable.Rout.save trunk/gdata/tests/test.reorder.factor.Rout.save trunk/gdata/tests/tests.write.fwf.Rout.save trunk/gdata/tests/unitTests/runit.write.fwf.R Modified: trunk/gdata/R/write.fwf.R =================================================================== --- trunk/gdata/R/write.fwf.R 2015-04-25 09:11:54 UTC (rev 1965) +++ trunk/gdata/R/write.fwf.R 2015-04-25 16:23:31 UTC (rev 1966) @@ -25,6 +25,16 @@ { ## --- Setup --- + dapply <- function(x, FUN, ..., simplify=TRUE) + { + if(is.data.frame(x)) + return(sapply(x, FUN, ..., simplify=simplify)) + else if(is.matrix(x)) + return(apply(x, 2, FUN, ...)) + else + stop("x must be a data.frame or a matrix") + } + if(!(is.data.frame(x) || is.matrix(x))) stop("'x' must be a data.frame or matrix") if(length(na) > 1) @@ -39,7 +49,7 @@ if(rownames) { - x <- cbind(rownames(x), x) + x <- cbind(rownames(x), as.data.frame(x)) rowColVal <- ifelse(!is.null(rowCol), rowCol, "row") colnames(x)[1] <- rowColVal } @@ -69,22 +79,26 @@ stringsAsFactors=FALSE) ## Which columns are numeric like - isNum <- apply(x, 2, is.numeric) + isNum <- dapply(x, is.numeric) ## is.numeric picks also Date and POSIXt - isNum <- isNum & !(apply(x, 2, inherits, what="Date") | - apply(x, 2, inherits, what="POSIXt")) + isNum <- isNum & !(dapply(x, inherits, what="Date") | + dapply(x, inherits, what="POSIXt")) ## Which columns are factors --> convert them to character - isFac <- apply(x, 2, is.factor) - x[, isFac] <- apply(x[, isFac, drop=FALSE], 2, as.character) + isFac <- dapply(x, is.factor) + if(any(isFac)) + ## This conditional is necessary because if x is a matrix, even if + ## all(isFAC==FALSE), this assignment will coerce it to mode + ## character. This isn't a problem for dataframes. + x[, isFac] <- sapply(x[, isFac, drop=FALSE], as.character) ## Collect information about how format() will format columns. ## We need to get this info now, since format will turn all columns to character - tmp <- apply(x, 2, format.info, ...) + tmp <- dapply(x, format.info, ..., simplify=FALSE) + if(is.matrix(x)) tmp <- as.data.frame(tmp) tmp1 <- sapply(tmp, length) tmp <- t(as.data.frame(tmp)) retFormat$width <- tmp[, 1] - ## Collect other details for numeric columns if(any(isNum)) { ## Numeric columns with digits @@ -100,6 +114,9 @@ ## --- Format --- + ## store original object in 'y' + y <- x + ## Formatting (to character) for(i in 1:nCol) { if(widthNULL) { @@ -112,17 +129,17 @@ ## following test to "fiddle" with the value in 'na' argument since - ## NA should not increase the width of column with width 1, while wider ## value for 'na' should increase the width - test <- is.na(x[, i]) + test <- is.na(y[, i]) ## Make a copy to make sure we get character after first format() - Date class caused problems x2 <- character(length=nRow) ## Add formatted values - x2[!test] <- format(x[!test, i], justify=justify, width=tmp, ...) + x2[!test] <- format(y[!test, i], justify=justify, width=tmp, ...) ## Add 'na' value x2[test] <- na ## Replace the original x[, i] <- x2 ## Collect width (again) - tmp2 <- format.info(x[, i], ...)[1] + tmp2 <- format.info(x2, ...)[1] ## Reformat if 'na' value change the width of the column if(tmp2 != retFormat[i, "width"]) { retFormat[i, "width"] <- tmp2 @@ -139,7 +156,7 @@ ## Number of levels for "non-numeric"" columns if(any(!isNum)) { - retFormat[!isNum, "nlevels"] <- apply(x[, !isNum, drop=FALSE], 2, + retFormat[!isNum, "nlevels"] <- dapply(x[, !isNum, drop=FALSE], function(z) length(unique(z))) } Modified: trunk/gdata/tests/test.humanReadable.Rout.save =================================================================== --- trunk/gdata/tests/test.humanReadable.Rout.save 2015-04-25 09:11:54 UTC (rev 1965) +++ trunk/gdata/tests/test.humanReadable.Rout.save 2015-04-25 16:23:31 UTC (rev 1966) @@ -1,14 +1,12 @@ -R version 3.1.2 (2014-10-31) -- "Pumpkin Helmet" -Copyright (C) 2014 The R Foundation for Statistical Computing +R version 3.2.0 (2015-04-16) -- "Full of Ingredients" +Copyright (C) 2015 The R Foundation for Statistical Computing Platform: x86_64-apple-darwin13.4.0 (64-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. - Natural language support but running in an English locale - R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. @@ -27,13 +25,13 @@ gdata: to automatically download and install the perl gdata: libaries needed to support Excel XLS and XLSX formats. -Attaching package: ‘gdata’ +Attaching package: 'gdata' -The following object is masked from ‘package:stats’: +The following object is masked from 'package:stats': nobs -The following object is masked from ‘package:utils’: +The following object is masked from 'package:utils': object.size @@ -65,26 +63,26 @@ + humanReadable(x=IEC2, standard="Unix", width=3)) [,1] [,2] [,3] [,4] [,5] [,6] [1,] " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " - [2,] "1.26838 kB" "1.268 kB" " 1.3 kB" "1.25729 KiB" "1.257 KiB" " 1.3 KiB" - [3,] " 1.2285 MB" "1.228 MB" " 1.2 MB" "1.83751 MiB" "1.838 MiB" " 1.8 MiB" - [4,] "1.24401 GB" "1.244 GB" " 1.2 GB" "1.26666 GiB" "1.267 GiB" " 1.3 GiB" - [5,] "1.47565 TB" "1.476 TB" " 1.5 TB" " 1.4234 TiB" "1.423 TiB" " 1.4 TiB" - [6,] "1.36687 PB" "1.367 PB" " 1.4 PB" "1.32499 PiB" "1.325 PiB" " 1.3 PiB" - [7,] "1.21324 EB" "1.213 EB" " 1.2 EB" "1.54391 EiB" "1.544 EiB" " 1.5 EiB" - [8,] "1.37186 ZB" "1.372 ZB" " 1.4 ZB" " 1.233 ZiB" "1.233 ZiB" " 1.2 ZiB" - [9,] "1.19468 YB" "1.195 YB" " 1.2 YB" "1.21258 YiB" "1.213 YiB" " 1.2 YiB" -[10,] "1201.13 YB" " 1201 YB" "1201 YB" "1489.01 YiB" " 1489 YiB" "1489 YiB" + [2,] "1.19855 kB" "1.199 kB" " 1.2 kB" "1.23404 KiB" "1.234 KiB" " 1.2 KiB" + [3,] "1.20686 MB" "1.207 MB" " 1.2 MB" "1.24529 MiB" "1.245 MiB" " 1.2 MiB" + [4,] "1.24218 GB" "1.242 GB" " 1.2 GB" "1.19621 GiB" "1.196 GiB" " 1.2 GiB" + [5,] "1.20157 TB" "1.202 TB" " 1.2 TB" "1.21737 TiB" "1.217 TiB" " 1.2 TiB" + [6,] "1.26255 PB" "1.263 PB" " 1.3 PB" "1.57268 PiB" "1.573 PiB" " 1.6 PiB" + [7,] "1.35911 EB" "1.359 EB" " 1.4 EB" "1.18177 EiB" "1.182 EiB" " 1.2 EiB" + [8,] " 1.2033 ZB" "1.203 ZB" " 1.2 ZB" "1.49049 ZiB" " 1.49 ZiB" " 1.5 ZiB" + [9,] "1.35332 YB" "1.353 YB" " 1.4 YB" "1.84401 YiB" "1.844 YiB" " 1.8 YiB" +[10,] " 1723.7 YB" " 1724 YB" "1724 YB" "1216.27 YiB" " 1216 YiB" "1216 YiB" [,7] [,8] [,9] [1,] " 2 B" " 2 B" " 2 B" - [2,] "1.25729 K" "1.257 K" " 1.3 K" - [3,] "1.83751 M" "1.838 M" " 1.8 M" - [4,] "1.26666 G" "1.267 G" " 1.3 G" - [5,] " 1.4234 T" "1.423 T" " 1.4 T" - [6,] "1.32499 P" "1.325 P" " 1.3 P" - [7,] "1.54391 E" "1.544 E" " 1.5 E" - [8,] " 1.233 Z" "1.233 Z" " 1.2 Z" - [9,] "1.21258 Y" "1.213 Y" " 1.2 Y" -[10,] "1489.01 Y" " 1489 Y" "1489 Y" + [2,] "1.23404 K" "1.234 K" " 1.2 K" + [3,] "1.24529 M" "1.245 M" " 1.2 M" + [4,] "1.19621 G" "1.196 G" " 1.2 G" + [5,] "1.21737 T" "1.217 T" " 1.2 T" + [6,] "1.57268 P" "1.573 P" " 1.6 P" + [7,] "1.18177 E" "1.182 E" " 1.2 E" + [8,] "1.49049 Z" " 1.49 Z" " 1.5 Z" + [9,] "1.84401 Y" "1.844 Y" " 1.8 Y" +[10,] "1216.27 Y" " 1216 Y" "1216 Y" > > # Auto units, specify digits > cbind(humanReadable(x=SI2, standard="SI", width=NULL, digits=7), @@ -101,37 +99,37 @@ + humanReadable(x=IEC2, standard="Unix", width=NULL, digits=1)) [,1] [,2] [,3] [,4] [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " - [2,] " 1.2683780 kB" " 1.268 kB" " 1.27 kB" " 1.3 kB" - [3,] " 1.2284981 MB" " 1.228 MB" " 1.23 MB" " 1.2 MB" - [4,] " 1.2440094 GB" " 1.244 GB" " 1.24 GB" " 1.2 GB" - [5,] " 1.4756474 TB" " 1.476 TB" " 1.48 TB" " 1.5 TB" - [6,] " 1.3668711 PB" " 1.367 PB" " 1.37 PB" " 1.4 PB" - [7,] " 1.2132416 EB" " 1.213 EB" " 1.21 EB" " 1.2 EB" - [8,] " 1.3718619 ZB" " 1.372 ZB" " 1.37 ZB" " 1.4 ZB" - [9,] " 1.1946775 YB" " 1.195 YB" " 1.19 YB" " 1.2 YB" -[10,] "1201.1346574 YB" "1201.135 YB" "1201.13 YB" "1201.1 YB" + [2,] " 1.1985486 kB" " 1.199 kB" " 1.20 kB" " 1.2 kB" + [3,] " 1.2068563 MB" " 1.207 MB" " 1.21 MB" " 1.2 MB" + [4,] " 1.2421751 GB" " 1.242 GB" " 1.24 GB" " 1.2 GB" + [5,] " 1.2015680 TB" " 1.202 TB" " 1.20 TB" " 1.2 TB" + [6,] " 1.2625549 PB" " 1.263 PB" " 1.26 PB" " 1.3 PB" + [7,] " 1.3591145 EB" " 1.359 EB" " 1.36 EB" " 1.4 EB" + [8,] " 1.2033002 ZB" " 1.203 ZB" " 1.20 ZB" " 1.2 ZB" + [9,] " 1.3533151 YB" " 1.353 YB" " 1.35 YB" " 1.4 YB" +[10,] "1723.7026620 YB" "1723.703 YB" "1723.70 YB" "1723.7 YB" [,5] [,6] [,7] [,8] [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " - [2,] " 1.2572859 KiB" " 1.257 KiB" " 1.26 KiB" " 1.3 KiB" - [3,] " 1.8375086 MiB" " 1.838 MiB" " 1.84 MiB" " 1.8 MiB" - [4,] " 1.2666626 GiB" " 1.267 GiB" " 1.27 GiB" " 1.3 GiB" - [5,] " 1.4234036 TiB" " 1.423 TiB" " 1.42 TiB" " 1.4 TiB" - [6,] " 1.3249855 PiB" " 1.325 PiB" " 1.32 PiB" " 1.3 PiB" - [7,] " 1.5439083 EiB" " 1.544 EiB" " 1.54 EiB" " 1.5 EiB" - [8,] " 1.2329980 ZiB" " 1.233 ZiB" " 1.23 ZiB" " 1.2 ZiB" - [9,] " 1.2125791 YiB" " 1.213 YiB" " 1.21 YiB" " 1.2 YiB" -[10,] "1489.0123170 YiB" "1489.012 YiB" "1489.01 YiB" "1489.0 YiB" + [2,] " 1.2340441 KiB" " 1.234 KiB" " 1.23 KiB" " 1.2 KiB" + [3,] " 1.2452876 MiB" " 1.245 MiB" " 1.25 MiB" " 1.2 MiB" + [4,] " 1.1962114 GiB" " 1.196 GiB" " 1.20 GiB" " 1.2 GiB" + [5,] " 1.2173697 TiB" " 1.217 TiB" " 1.22 TiB" " 1.2 TiB" + [6,] " 1.5726781 PiB" " 1.573 PiB" " 1.57 PiB" " 1.6 PiB" + [7,] " 1.1817693 EiB" " 1.182 EiB" " 1.18 EiB" " 1.2 EiB" + [8,] " 1.4904906 ZiB" " 1.490 ZiB" " 1.49 ZiB" " 1.5 ZiB" + [9,] " 1.8440055 YiB" " 1.844 YiB" " 1.84 YiB" " 1.8 YiB" +[10,] "1216.2741325 YiB" "1216.274 YiB" "1216.27 YiB" "1216.3 YiB" [,9] [,10] [,11] [,12] [1,] " 1.5000000 B" " 1.500 B" " 1.50 B" " 1.5 B" - [2,] " 1.2572859 K" " 1.257 K" " 1.26 K" " 1.3 K" - [3,] " 1.8375086 M" " 1.838 M" " 1.84 M" " 1.8 M" - [4,] " 1.2666626 G" " 1.267 G" " 1.27 G" " 1.3 G" - [5,] " 1.4234036 T" " 1.423 T" " 1.42 T" " 1.4 T" - [6,] " 1.3249855 P" " 1.325 P" " 1.32 P" " 1.3 P" - [7,] " 1.5439083 E" " 1.544 E" " 1.54 E" " 1.5 E" - [8,] " 1.2329980 Z" " 1.233 Z" " 1.23 Z" " 1.2 Z" - [9,] " 1.2125791 Y" " 1.213 Y" " 1.21 Y" " 1.2 Y" -[10,] "1489.0123170 Y" "1489.012 Y" "1489.01 Y" "1489.0 Y" + [2,] " 1.2340441 K" " 1.234 K" " 1.23 K" " 1.2 K" + [3,] " 1.2452876 M" " 1.245 M" " 1.25 M" " 1.2 M" + [4,] " 1.1962114 G" " 1.196 G" " 1.20 G" " 1.2 G" + [5,] " 1.2173697 T" " 1.217 T" " 1.22 T" " 1.2 T" + [6,] " 1.5726781 P" " 1.573 P" " 1.57 P" " 1.6 P" + [7,] " 1.1817693 E" " 1.182 E" " 1.18 E" " 1.2 E" + [8,] " 1.4904906 Z" " 1.490 Z" " 1.49 Z" " 1.5 Z" + [9,] " 1.8440055 Y" " 1.844 Y" " 1.84 Y" " 1.8 Y" +[10,] "1216.2741325 Y" "1216.274 Y" "1216.27 Y" "1216.3 Y" > > # Single unit, specify width > cbind(humanReadable(x=SI1, units="GB", standard="SI", width=7), @@ -146,26 +144,26 @@ + ) [,1] [,2] [,3] [,4] [,5] [,6] [1,] "5e-10 GB" "5e-10 GB" "5e-10 GB" "5e-10 GiB" "5e-10 GiB" "5e-10 GiB" - [2,] "6e-07 GB" "6e-07 GB" "6e-07 GB" "6e-07 GiB" "6e-07 GiB" "6e-07 GiB" - [3,] "7e-04 GB" "7e-04 GB" "7e-04 GB" "7e-04 GiB" "7e-04 GiB" "7e-04 GiB" + [2,] "8e-07 GB" "8e-07 GB" "8e-07 GB" "7e-07 GiB" "7e-07 GiB" "7e-07 GiB" + [3,] "8e-04 GB" "8e-04 GB" "8e-04 GB" "8e-04 GiB" "8e-04 GiB" "8e-04 GiB" [4,] "8e-01 GB" "8e-01 GB" "8e-01 GB" "8e-01 GiB" "8e-01 GiB" "8e-01 GiB" - [5,] "7e+02 GB" "7e+02 GB" "7e+02 GB" "3e+02 GiB" "3e+02 GiB" "3e+02 GiB" - [6,] "8e+05 GB" "8e+05 GB" "8e+05 GB" "7e+05 GiB" "7e+05 GiB" "7e+05 GiB" + [5,] "8e+02 GB" "8e+02 GB" "8e+02 GB" "6e+02 GiB" "6e+02 GiB" "6e+02 GiB" + [6,] "8e+05 GB" "8e+05 GB" "8e+05 GB" "6e+05 GiB" "6e+05 GiB" "6e+05 GiB" [7,] "8e+08 GB" "8e+08 GB" "8e+08 GB" "8e+08 GiB" "8e+08 GiB" "8e+08 GiB" - [8,] "8e+11 GB" "8e+11 GB" "8e+11 GB" "5e+11 GiB" "5e+11 GiB" "5e+11 GiB" - [9,] "7e+14 GB" "7e+14 GB" "7e+14 GB" "9e+14 GiB" "9e+14 GiB" "9e+14 GiB" -[10,] "8e+17 GB" "8e+17 GB" "8e+17 GB" "6e+17 GiB" "6e+17 GiB" "6e+17 GiB" + [8,] "8e+11 GB" "8e+11 GB" "8e+11 GB" "9e+11 GiB" "9e+11 GiB" "9e+11 GiB" + [9,] "8e+14 GB" "8e+14 GB" "8e+14 GB" "4e+14 GiB" "4e+14 GiB" "4e+14 GiB" +[10,] "7e+17 GB" "7e+17 GB" "7e+17 GB" "8e+17 GiB" "8e+17 GiB" "8e+17 GiB" [,7] [,8] [,9] [1,] "5e-10 G" "5e-10 G" "5e-10 G" - [2,] "6e-07 G" "6e-07 G" "6e-07 G" - [3,] "7e-04 G" "7e-04 G" "7e-04 G" + [2,] "7e-07 G" "7e-07 G" "7e-07 G" + [3,] "8e-04 G" "8e-04 G" "8e-04 G" [4,] "8e-01 G" "8e-01 G" "8e-01 G" - [5,] "3e+02 G" "3e+02 G" "3e+02 G" - [6,] "7e+05 G" "7e+05 G" "7e+05 G" + [5,] "6e+02 G" "6e+02 G" "6e+02 G" + [6,] "6e+05 G" "6e+05 G" "6e+05 G" [7,] "8e+08 G" "8e+08 G" "8e+08 G" - [8,] "5e+11 G" "5e+11 G" "5e+11 G" - [9,] "9e+14 G" "9e+14 G" "9e+14 G" -[10,] "6e+17 G" "6e+17 G" "6e+17 G" + [8,] "9e+11 G" "9e+11 G" "9e+11 G" + [9,] "4e+14 G" "4e+14 G" "4e+14 G" +[10,] "8e+17 G" "8e+17 G" "8e+17 G" > > # Single unit, specify digits > cbind(humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=7), @@ -183,37 +181,37 @@ + ) [,1] [,2] [,3] [,4] [1,] "5.000000e-10 GB" "5.00e-10 GB" "5.0e-10 GB" "5e-10 GB" - [2,] "6.388137e-07 GB" "6.39e-07 GB" "6.4e-07 GB" "6e-07 GB" - [3,] "7.101117e-04 GB" "7.10e-04 GB" "7.1e-04 GB" "7e-04 GB" - [4,] "8.188110e-01 GB" "8.19e-01 GB" "8.2e-01 GB" "8e-01 GB" - [5,] "6.706597e+02 GB" "6.71e+02 GB" "6.7e+02 GB" "7e+02 GB" - [6,] "8.067884e+05 GB" "8.07e+05 GB" "8.1e+05 GB" "8e+05 GB" - [7,] "7.758668e+08 GB" "7.76e+08 GB" "7.8e+08 GB" "8e+08 GB" - [8,] "7.861707e+11 GB" "7.86e+11 GB" "7.9e+11 GB" "8e+11 GB" - [9,] "7.495958e+14 GB" "7.50e+14 GB" "7.5e+14 GB" "7e+14 GB" -[10,] "7.655714e+17 GB" "7.66e+17 GB" "7.7e+17 GB" "8e+17 GB" + [2,] "7.792994e-07 GB" "7.79e-07 GB" "7.8e-07 GB" "8e-07 GB" + [3,] "7.796269e-04 GB" "7.80e-04 GB" "7.8e-04 GB" "8e-04 GB" + [4,] "8.033561e-01 GB" "8.03e-01 GB" "8.0e-01 GB" "8e-01 GB" + [5,] "8.314840e+02 GB" "8.31e+02 GB" "8.3e+02 GB" "8e+02 GB" + [6,] "8.018065e+05 GB" "8.02e+05 GB" "8.0e+05 GB" "8e+05 GB" + [7,] "8.032533e+08 GB" "8.03e+08 GB" "8.0e+08 GB" "8e+08 GB" + [8,] "7.736007e+11 GB" "7.74e+11 GB" "7.7e+11 GB" "8e+11 GB" + [9,] "8.033881e+14 GB" "8.03e+14 GB" "8.0e+14 GB" "8e+14 GB" +[10,] "6.856332e+17 GB" "6.86e+17 GB" "6.9e+17 GB" "7e+17 GB" [,5] [,6] [,7] [,8] [1,] "4.656613e-10 GiB" "4.66e-10 GiB" "4.7e-10 GiB" "5e-10 GiB" - [2,] "6.058649e-07 GiB" "6.06e-07 GiB" "6.1e-07 GiB" "6e-07 GiB" - [3,] "7.437373e-04 GiB" "7.44e-04 GiB" "7.4e-04 GiB" "7e-04 GiB" - [4,] "7.890501e-01 GiB" "7.89e-01 GiB" "7.9e-01 GiB" "8e-01 GiB" - [5,] "2.665461e+02 GiB" "2.67e+02 GiB" "2.7e+02 GiB" "3e+02 GiB" - [6,] "6.781352e+05 GiB" "6.78e+05 GiB" "6.8e+05 GiB" "7e+05 GiB" - [7,] "7.658425e+08 GiB" "7.66e+08 GiB" "7.7e+08 GiB" "8e+08 GiB" - [8,] "4.681329e+11 GiB" "4.68e+11 GiB" "4.7e+11 GiB" "5e+11 GiB" - [9,] "8.705167e+14 GiB" "8.71e+14 GiB" "8.7e+14 GiB" "9e+14 GiB" -[10,] "6.227605e+17 GiB" "6.23e+17 GiB" "6.2e+17 GiB" "6e+17 GiB" + [2,] "7.138398e-07 GiB" "7.14e-07 GiB" "7.1e-07 GiB" "7e-07 GiB" + [3,] "7.600841e-04 GiB" "7.60e-04 GiB" "7.6e-04 GiB" "8e-04 GiB" + [4,] "8.231780e-01 GiB" "8.23e-01 GiB" "8.2e-01 GiB" "8e-01 GiB" + [5,] "5.678312e+02 GiB" "5.68e+02 GiB" "5.7e+02 GiB" "6e+02 GiB" + [6,] "5.506880e+05 GiB" "5.51e+05 GiB" "5.5e+05 GiB" "6e+05 GiB" + [7,] "8.221636e+08 GiB" "8.22e+08 GiB" "8.2e+08 GiB" "8e+08 GiB" + [8,] "8.721612e+11 GiB" "8.72e+11 GiB" "8.7e+11 GiB" "9e+11 GiB" + [9,] "4.356026e+14 GiB" "4.36e+14 GiB" "4.4e+14 GiB" "4e+14 GiB" +[10,] "8.080586e+17 GiB" "8.08e+17 GiB" "8.1e+17 GiB" "8e+17 GiB" [,9] [,10] [,11] [,12] [1,] "4.656613e-10 G" "4.66e-10 G" "4.7e-10 G" "5e-10 G" - [2,] "6.058649e-07 G" "6.06e-07 G" "6.1e-07 G" "6e-07 G" - [3,] "7.437373e-04 G" "7.44e-04 G" "7.4e-04 G" "7e-04 G" - [4,] "7.890501e-01 G" "7.89e-01 G" "7.9e-01 G" "8e-01 G" - [5,] "2.665461e+02 G" "2.67e+02 G" "2.7e+02 G" "3e+02 G" - [6,] "6.781352e+05 G" "6.78e+05 G" "6.8e+05 G" "7e+05 G" - [7,] "7.658425e+08 G" "7.66e+08 G" "7.7e+08 G" "8e+08 G" - [8,] "4.681329e+11 G" "4.68e+11 G" "4.7e+11 G" "5e+11 G" - [9,] "8.705167e+14 G" "8.71e+14 G" "8.7e+14 G" "9e+14 G" -[10,] "6.227605e+17 G" "6.23e+17 G" "6.2e+17 G" "6e+17 G" + [2,] "7.138398e-07 G" "7.14e-07 G" "7.1e-07 G" "7e-07 G" + [3,] "7.600841e-04 G" "7.60e-04 G" "7.6e-04 G" "8e-04 G" + [4,] "8.231780e-01 G" "8.23e-01 G" "8.2e-01 G" "8e-01 G" + [5,] "5.678312e+02 G" "5.68e+02 G" "5.7e+02 G" "6e+02 G" + [6,] "5.506880e+05 G" "5.51e+05 G" "5.5e+05 G" "6e+05 G" + [7,] "8.221636e+08 G" "8.22e+08 G" "8.2e+08 G" "8e+08 G" + [8,] "8.721612e+11 G" "8.72e+11 G" "8.7e+11 G" "9e+11 G" + [9,] "4.356026e+14 G" "4.36e+14 G" "4.4e+14 G" "4e+14 G" +[10,] "8.080586e+17 G" "8.08e+17 G" "8.1e+17 G" "8e+17 G" > > > stopifnot( is.object_sizes(as.object_sizes( 2^(1:30) ) ) ) @@ -240,4 +238,4 @@ > > proc.time() user system elapsed - 0.411 0.048 0.455 + 0.368 0.047 0.415 Modified: trunk/gdata/tests/test.reorder.factor.Rout.save =================================================================== --- trunk/gdata/tests/test.reorder.factor.Rout.save 2015-04-25 09:11:54 UTC (rev 1965) +++ trunk/gdata/tests/test.reorder.factor.Rout.save 2015-04-25 16:23:31 UTC (rev 1966) @@ -1,14 +1,12 @@ -R version 3.1.2 (2014-10-31) -- "Pumpkin Helmet" -Copyright (C) 2014 The R Foundation for Statistical Computing -Platform: x86_64-unknown-linux-gnu (64-bit) +R version 3.2.0 (2015-04-16) -- "Full of Ingredients" +Copyright (C) 2015 The R Foundation for Statistical Computing +Platform: x86_64-apple-darwin13.4.0 (64-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. - Natural language support but running in an English locale - R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. @@ -31,20 +29,23 @@ > library(gdata) gdata: read.xls support for 'XLS' (Excel 97-2004) files ENABLED. -gdata: read.xls support for 'XLSX' (Excel 2007+) files ENABLED. +gdata: Unable to load perl libaries needed by read.xls() +gdata: to support 'XLSX' (Excel 2007+) files. -Attaching package: ‘gdata’ +gdata: Run the function 'installXLSXsupport()' +gdata: to automatically download and install the perl +gdata: libaries needed to support Excel XLS and XLSX formats. -The following object is masked from ‘package:stats’: +Attaching package: 'gdata' +The following object is masked from 'package:stats': + nobs -The following object is masked from ‘package:utils’: +The following object is masked from 'package:utils': object.size -Warning message: -S3 methods ‘print.object_size’, ‘c.object_size’ were declared in NAMESPACE but not found > > ( m2 <- reorder(m, X=c(3, 2, 1)) ) [1] a b c @@ -57,4 +58,4 @@ > > proc.time() user system elapsed - 0.512 0.070 0.638 + 0.300 0.049 0.345 Modified: trunk/gdata/tests/tests.write.fwf.Rout.save =================================================================== --- trunk/gdata/tests/tests.write.fwf.Rout.save 2015-04-25 09:11:54 UTC (rev 1965) +++ trunk/gdata/tests/tests.write.fwf.Rout.save 2015-04-25 16:23:31 UTC (rev 1966) @@ -1,7 +1,7 @@ -R version 3.1.0 Patched (2014-05-26 r65771) -- "Spring Dance" -Copyright (C) 2014 The R Foundation for Statistical Computing -Platform: x86_64-apple-darwin13.1.0 (64-bit) +R version 3.2.0 (2015-04-16) -- "Full of Ingredients" +Copyright (C) 2015 The R Foundation for Statistical Computing +Platform: x86_64-apple-darwin13.4.0 (64-bit) R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. @@ -25,8 +25,13 @@ > library(gdata) gdata: read.xls support for 'XLS' (Excel 97-2004) files ENABLED. -gdata: read.xls support for 'XLSX' (Excel 2007+) files ENABLED. +gdata: Unable to load perl libaries needed by read.xls() +gdata: to support 'XLSX' (Excel 2007+) files. +gdata: Run the function 'installXLSXsupport()' +gdata: to automatically download and install the perl +gdata: libaries needed to support Excel XLS and XLSX formats. + Attaching package: 'gdata' The following object is masked from 'package:stats': @@ -80,7 +85,7 @@ > ## NA should be - > write.fwf(x=testData, na="-") num1 num2 num3 int1 fac1 fac2 cha1 cha2 Date POSIXt - 1 - - 1 - f q - 1900-01-01 1900-01-01 01:01:01 + 1 - - 1 - f q - 1900-01-01 1900-01-01 01:01:01 2 1.0 733070.3 2 a g r longer - 1900-01-01 01:01:01 3 1.5 1214213.8 3 b h s y 1900-01-01 1900-01-01 01:01:01 4 2.0 553823.8 4 c i t x 1900-01-01 1900-01-01 01:01:01 @@ -90,21 +95,21 @@ 8 4.0 1053686.6 6 g m x t 1900-01-01 1900-01-01 01:01:01 9 4.5 971024.2 7 h n y s 1900-01-01 1900-01-01 01:01:01 10 5.0 631193.4 8 i o z r 1900-01-01 1900-01-01 01:01:01 - - 5.5 879431.1 9 hjh - - q 1900-01-01 1900-01-01 01:01:01 +- 5.5 879431.1 9 hjh - - q 1900-01-01 1900-01-01 01:01:01 > ## NA should be -NA- > write.fwf(x=testData, na="-NA-") num1 num2 num3 int1 fac1 fac2 cha1 cha2 Date POSIXt - 1 -NA- -NA- 1 -NA- f q -NA- 1900-01-01 1900-01-01 01:01:01 - 2 1.0 733070.3 2 a g r longer -NA- 1900-01-01 01:01:01 - 3 1.5 1214213.8 3 b h s y 1900-01-01 1900-01-01 01:01:01 - 4 2.0 553823.8 4 c i t x 1900-01-01 1900-01-01 01:01:01 - 5 2.5 1085022.9 -NA- d j u w 1900-01-01 -NA- - 6 3.0 571063.9 4 e k v v 1900-01-01 1900-01-01 01:01:01 - 7 3.5 606718.4 5 f l w u 1900-01-01 1900-01-01 01:01:01 - 8 4.0 1053686.6 6 g m x t 1900-01-01 1900-01-01 01:01:01 - 9 4.5 971024.2 7 h n y s 1900-01-01 1900-01-01 01:01:01 - 10 5.0 631193.4 8 i o z r 1900-01-01 1900-01-01 01:01:01 --NA- 5.5 879431.1 9 hjh -NA- -NA- q 1900-01-01 1900-01-01 01:01:01 + 1 -NA- -NA- 1 -NA- f q -NA- 1900-01-01 1900-01-01 01:01:01 + 2 1.0 733070.3 2 a g r longer -NA- 1900-01-01 01:01:01 + 3 1.5 1214213.8 3 b h s y 1900-01-01 1900-01-01 01:01:01 + 4 2.0 553823.8 4 c i t x 1900-01-01 1900-01-01 01:01:01 + 5 2.5 1085022.9 -NA- d j u w 1900-01-01 -NA- + 6 3.0 571063.9 4 e k v v 1900-01-01 1900-01-01 01:01:01 + 7 3.5 606718.4 5 f l w u 1900-01-01 1900-01-01 01:01:01 + 8 4.0 1053686.6 6 g m x t 1900-01-01 1900-01-01 01:01:01 + 9 4.5 971024.2 7 h n y s 1900-01-01 1900-01-01 01:01:01 +10 5.0 631193.4 8 i o z r 1900-01-01 1900-01-01 01:01:01 +-NA- 5.5 879431.1 9 hjh -NA- -NA- q 1900-01-01 1900-01-01 01:01:01 > > ## Some other separator than space > write.fwf(testData[, 1:4], sep="-mySep-") @@ -231,4 +236,4 @@ > > proc.time() user system elapsed - 0.388 0.041 0.422 + 0.413 0.044 0.448 Modified: trunk/gdata/tests/unitTests/runit.write.fwf.R =================================================================== --- trunk/gdata/tests/unitTests/runit.write.fwf.R 2015-04-25 09:11:54 UTC (rev 1965) +++ trunk/gdata/tests/unitTests/runit.write.fwf.R 2015-04-25 16:23:31 UTC (rev 1966) @@ -59,9 +59,17 @@ digits=c(0, 1), exp=c(0, 0), stringsAsFactors=FALSE) - formatInfo <- write.fwf(testData[, c("num1", "num2")], formatInfo=TRUE) + + testData1 <- testData[, c("num1", "num2")] + testData1M <- as.matrix(testData1) + + formatInfo <- write.fwf(testData1, formatInfo=TRUE) checkEquals(formatInfo, formatInfoT) + formatInfoM <- write.fwf(testData1M, formatInfo=TRUE) + checkEquals(formatInfoM, formatInfoT) + + ## scientific notation dd <- options("digits"); options(digits = 7) testData2 <- data.frame(a=123, b=pi, c=1e8, d=1e222) @@ -91,39 +99,66 @@ digits=c(0, 0, 1), exp=c(0, 0, 0), stringsAsFactors=FALSE) - formatInfoR <- write.fwf(testData[, c("num1", "num2")], formatInfo=TRUE, - rownames=TRUE, rowCol="row") + testData3 <- testData[, c("num1", "num2")] + testData3M <- as.matrix(testData3) + + formatInfoR <- write.fwf(testData3, formatInfo=TRUE, rownames=TRUE, + rowCol="row") checkEquals(formatInfoR, formatInfoTR) + formatInfoR <- write.fwf(testData3M, formatInfo=TRUE, rownames=TRUE, + rowCol="row") + checkEquals(formatInfoR, formatInfoTR) + + ## quoteInfo alone does not have any effect - formatInfoI <- write.fwf(testData[, c("num1", "num2")], formatInfo=TRUE, - quoteInfo=TRUE) + formatInfoI <- write.fwf(testData3, formatInfo=TRUE, quoteInfo=TRUE) checkEquals(formatInfoI, formatInfoT) + formatInfoI <- write.fwf(testData3M, formatInfo=TRUE, quoteInfo=TRUE) + checkEquals(formatInfoI, formatInfoT) + ## quote - formatInfoQ <- write.fwf(testData[, c("num1", "num2")], formatInfo=TRUE, - quote=TRUE) formatInfoTQ <- formatInfoT formatInfoTQ$position <- c(1, 6) formatInfoTQ$width <- c(4, 5) + + formatInfoQ <- write.fwf(testData3, formatInfo=TRUE, quote=TRUE) checkEquals(formatInfoQ, formatInfoTQ) + formatInfoQ <- write.fwf(testData3M, formatInfo=TRUE, quote=TRUE) + checkEquals(formatInfoQ, formatInfoTQ) + ## quote without quoteInfo - formatInfoQI <- write.fwf(testData[, c("num1", "num2")], formatInfo=TRUE, - quote=TRUE, quoteInfo=FALSE) formatInfoTQI <- formatInfoT formatInfoTQI$position <- c(2, 6) + + formatInfoQI <- write.fwf(testData3, formatInfo=TRUE, quote=TRUE, + quoteInfo=FALSE) checkEquals(formatInfoQI, formatInfoTQI) + formatInfoQI <- write.fwf(testData3M, formatInfo=TRUE, quote=TRUE, + quoteInfo=FALSE) + checkEquals(formatInfoQI, formatInfoTQI) + ## width ## --> default width for num1 is 2 - formatInfo <- write.fwf(testData[, "num1", drop=FALSE], width=10, formatInfo=TRUE) + testData4 <- testData[, "num1", drop=FALSE] + testData4M <- as.matrix(testData[, "num1", drop=FALSE]) + + formatInfo <- write.fwf(testData4, width=10, formatInfo=TRUE) checkEquals(formatInfo$width, 10) + formatInfo <- write.fwf(testData4M, width=10, formatInfo=TRUE) + checkEquals(formatInfo$width, 10) + ## too small value in width (this also tests recycling) ## --> proper width for num1 is 2, while for num2 it is 3 checkException(write.fwf(testData[, c("num1", "num2")], width=2)) checkException(write.fwf(testData[, c("num1", "num2")], width=c(2, 1))) + + ## Done + cat("\nDONE.\n\n") } ### }}} This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 09:12:01
|
Revision: 1965 http://sourceforge.net/p/r-gregmisc/code/1965 Author: warnes Date: 2015-04-25 09:11:54 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Installing PERL modules was failing. Adding CPAN configuration option fixed the problem. Modified Paths: -------------- trunk/gdata/inst/perl/module_tools.pl Modified: trunk/gdata/inst/perl/module_tools.pl =================================================================== --- trunk/gdata/inst/perl/module_tools.pl 2015-04-25 08:49:41 UTC (rev 1964) +++ trunk/gdata/inst/perl/module_tools.pl 2015-04-25 09:11:54 UTC (rev 1965) @@ -91,6 +91,8 @@ CPAN::Index->reload(); # set the target install path + CPAN::Shell->o("conf", "mbuildpl_arg", + "PREFIX=$here LIB=$here --prefix $here --install-base $here"); CPAN::Shell->o("conf", "makepl_arg", "PREFIX=$here LIB=$here --prefix $here --install-base $here"); CPAN::Shell->install("Compress::Raw::Zlib"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 08:49:48
|
Revision: 1964 http://sourceforge.net/p/r-gregmisc/code/1964 Author: warnes Date: 2015-04-25 08:49:41 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Error message about executable name was missing one alternative Modified Paths: -------------- trunk/gdata/inst/perl/xls2csv.pl Modified: trunk/gdata/inst/perl/xls2csv.pl =================================================================== --- trunk/gdata/inst/perl/xls2csv.pl 2015-04-25 07:59:03 UTC (rev 1963) +++ trunk/gdata/inst/perl/xls2csv.pl 2015-04-25 08:49:41 UTC (rev 1964) @@ -1,9 +1,9 @@ #!/usr/bin/perl BEGIN { -use File::Basename; -# Add current path to perl library search path -use lib dirname($0); + use File::Basename; + # Add current path to perl library search path + use lib dirname($0); } use strict; @@ -61,7 +61,7 @@ } else { - die("This script is named '$whoami', but must be named either 'xls2csv.pl' or 'xls2tab.pl' to function properly.\n"); + die("This script is named '$whoami', but must be named 'xls2csv.pl', 'xls2tsv', or 'xls2tab.pl' to function properly.\n"); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 07:59:05
|
Revision: 1963 http://sourceforge.net/p/r-gregmisc/code/1963 Author: warnes Date: 2015-04-25 07:59:03 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Better describe gdata contents Modified Paths: -------------- trunk/gdata/DESCRIPTION Modified: trunk/gdata/DESCRIPTION =================================================================== --- trunk/gdata/DESCRIPTION 2015-04-25 07:58:18 UTC (rev 1962) +++ trunk/gdata/DESCRIPTION 2015-04-25 07:59:03 UTC (rev 1963) @@ -1,6 +1,25 @@ Package: gdata Title: Various R Programming Tools for Data Manipulation -Description: Various R programming tools for data manipulation +Description: Various R programming tools for data manipulation, including: + - medical unit conversions ('ConvertMedUnits', 'MedUnits'), + - combining objects ('bindData', 'cbindX', 'combine', 'interleave'), + - character vector operations ('centerText', 'startsWith', 'trim'), + - factor manipulation ('levels', 'reorder.factor', 'mapLevels'), + - obtaining information about R objects ('object.size', 'elem', 'env', + 'humanReadable', 'is.what', 'll', 'keep', 'ls.funs', + 'Args','nPairs', 'nobs'), + - manipulating MS-Excel formatted files ('read.xls', + 'installXLSXsupport', 'sheetCount', 'xlsFormats'), + - generating fixed-width format files ('write.fwf'), + - extrating compoents of date & time objects ('getYear', 'getMonth', + 'getDay', 'getHour', 'getMin', 'getSec'), + - operations on columns of data frames ('matchcols', 'rename.vars'), + - matrix operations ('unmatrix', 'upperTriangle', 'lowerTriangle'), + - operations on vectors ('case', 'unknownToNA', 'duplicated2', 'trimSum'), + - operations on data frames ('frameApply', 'wideByFactor'), + - value of last evaluated expression ('ans'), + - wrapper for 'sample' that ensures consistent behavior for both + scalar and vector arguments ('resample'). Depends: R (>= 2.13.0) SystemRequirements: perl Imports: gtools This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 07:58:25
|
Revision: 1962 http://sourceforge.net/p/r-gregmisc/code/1962 Author: warnes Date: 2015-04-25 07:58:18 +0000 (Sat, 25 Apr 2015) Log Message: ----------- is.* and as.* aren't generics Modified Paths: -------------- trunk/gdata/NAMESPACE Modified: trunk/gdata/NAMESPACE =================================================================== --- trunk/gdata/NAMESPACE 2015-04-25 07:57:39 UTC (rev 1961) +++ trunk/gdata/NAMESPACE 2015-04-25 07:58:18 UTC (rev 1962) @@ -130,9 +130,7 @@ ## Object size stuff S3method(c, object_sizes) -S3method(as, object_sizes) S3method(format, object_sizes) -S3method(is, object_sizes) S3method(print, object_sizes) ## unknown stuff This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 07:57:41
|
Revision: 1961 http://sourceforge.net/p/r-gregmisc/code/1961 Author: warnes Date: 2015-04-25 07:57:39 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Add 'justify' argument to print and format object_sizes methods Modified Paths: -------------- trunk/gdata/man/humanReadable.Rd trunk/gdata/man/object.size.Rd Modified: trunk/gdata/man/humanReadable.Rd =================================================================== --- trunk/gdata/man/humanReadable.Rd 2015-04-25 07:57:16 UTC (rev 1960) +++ trunk/gdata/man/humanReadable.Rd 2015-04-25 07:57:39 UTC (rev 1961) @@ -13,8 +13,7 @@ \usage{ humanReadable(x, units="auto", standard=c("IEC", "SI", "Unix"), - digits=1, width=NULL, sep=" ", justify=c("right", "left"), - \dots) + digits=1, width=NULL, sep=" ", justify=c("right", "left") ) } \arguments{ Modified: trunk/gdata/man/object.size.Rd =================================================================== --- trunk/gdata/man/object.size.Rd 2015-04-25 07:57:16 UTC (rev 1960) +++ trunk/gdata/man/object.size.Rd 2015-04-25 07:57:39 UTC (rev 1961) @@ -22,26 +22,30 @@ \method{as}{object_sizes}(x) -\method{c}{object_sizes}(x) +\method{c}{object_sizes}(\dots, recursive=FALSE) \method{format}{object_sizes}(x, humanReadable=getOption("humanReadable"), standard="IEC", units, - digits=1, width=NULL, sep=" ", \dots) + digits=1, width=NULL, sep=" ", justify = c("right", "left"), +\dots) -\method{print}{object_sizes}x, quote=FALSE, humanReadable=getOption("humanReadable"), - standard="IEC", units, digits=1, width=NULL, sep=" ", \dots) +\method{print}{object_sizes}(x, quote=FALSE, humanReadable=getOption("humanReadable"), + standard="IEC", units, digits=1, width=NULL, sep=" ", + justify = c("right", "left"), \dots) } \arguments{ \item{\dots}{\code{object.size}: \R objects; - \code{print}: arguments to be passed to other methods.} + \code{print} and \code{format}: arguments to be passed to other + methods. + } \item{x}{output from \code{object.size}} \item{quote}{logical, indicating whether or not the result should be printed with surrounding quotes.} \item{humanReadable}{logical, use the \dQuote{human readable} format.} - \item{standard,units,digits,width,sep,justify}{arguments passed to - \code{\link{humanReadable}}. See the \code{\link{humanReadable}} - man page for details. - } + \item{standard,units,digits,width,sep,justify}{See the man page for + \code{\link{humanReadable}}. + } + \item{recursive}{See the man page for \code{\link[base]{c}}. } } \details{ @@ -60,7 +64,7 @@ space needed to store its name in the symbol table. Associated space (e.g., the environment of a function and what the - pointer in a ‘EXTPTRSXP’ points to) is not included in the + pointer in a \code{EXTPTRSXP} points to) is not included in the calculation. Object sizes are larger on 64-bit builds than 32-bit ones, but This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 07:57:23
|
Revision: 1960 http://sourceforge.net/p/r-gregmisc/code/1960 Author: warnes Date: 2015-04-25 07:57:16 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Add 'justify' argument to print and format object_sizes methods Modified Paths: -------------- trunk/gdata/R/humanReadable.R trunk/gdata/R/object.size.R Modified: trunk/gdata/R/humanReadable.R =================================================================== --- trunk/gdata/R/humanReadable.R 2015-04-25 07:56:23 UTC (rev 1959) +++ trunk/gdata/R/humanReadable.R 2015-04-25 07:57:16 UTC (rev 1960) @@ -4,8 +4,7 @@ digits=1, width=NULL, sep=" ", - justify = c("right", "left"), - ... + justify = c("right", "left") ) { ## --- Setup --- Modified: trunk/gdata/R/object.size.R =================================================================== --- trunk/gdata/R/object.size.R 2015-04-25 07:56:23 UTC (rev 1959) +++ trunk/gdata/R/object.size.R 2015-04-25 07:57:16 UTC (rev 1960) @@ -16,6 +16,7 @@ digits=1, width=NULL, sep=" ", + justify = c("right", "left"), ...) { print(format(x, @@ -24,7 +25,8 @@ units=units, digits=digits, width=width, - sep=sep), + sep=sep, + justify=justify), quote=quote, ...) @@ -39,6 +41,7 @@ digits=1, width=NULL, sep=" ", + justify = c("right", "left"), ...) { if( !missing(units) ) @@ -51,7 +54,8 @@ units=units, digits=digits, width=width, - sep=sep + sep=sep, + justify=justify ) } else if( is.null(humanReadable) || humanReadable==FALSE ) @@ -62,7 +66,8 @@ units=units, digits=digits, width=width, - sep=sep) + sep=sep, + justify=justify) } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 07:56:25
|
Revision: 1959 http://sourceforge.net/p/r-gregmisc/code/1959 Author: warnes Date: 2015-04-25 07:56:23 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Remove stray call to 'browser' Modified Paths: -------------- trunk/gdata/R/write.fwf.R Modified: trunk/gdata/R/write.fwf.R =================================================================== --- trunk/gdata/R/write.fwf.R 2015-04-25 06:26:40 UTC (rev 1958) +++ trunk/gdata/R/write.fwf.R 2015-04-25 07:56:23 UTC (rev 1959) @@ -37,7 +37,7 @@ options("scipen"=100) } - + if(rownames) { x <- cbind(rownames(x), x) rowColVal <- ifelse(!is.null(rowCol), rowCol, "row") @@ -80,8 +80,6 @@ ## Collect information about how format() will format columns. ## We need to get this info now, since format will turn all columns to character -browser() - tmp <- apply(x, 2, format.info, ...) tmp1 <- sapply(tmp, length) tmp <- t(as.data.frame(tmp)) @@ -171,7 +169,7 @@ na=na, row.names=FALSE, col.names=FALSE, - qmethod=qmethod) + qmethod=qmethod) } write.table(x=x, This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 06:26:53
|
Revision: 1958 http://sourceforge.net/p/r-gregmisc/code/1958 Author: warnes Date: 2015-04-25 06:26:40 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Update DESCRIPTION, ChangeLog, and NEWS Modified Paths: -------------- trunk/gdata/DESCRIPTION trunk/gdata/inst/ChangeLog trunk/gdata/inst/NEWS Modified: trunk/gdata/DESCRIPTION =================================================================== --- trunk/gdata/DESCRIPTION 2015-04-25 05:54:28 UTC (rev 1957) +++ trunk/gdata/DESCRIPTION 2015-04-25 06:26:40 UTC (rev 1958) @@ -5,7 +5,7 @@ SystemRequirements: perl Imports: gtools Version: 2.16.0 -Date: 2015-04-21 +Date: 2015-04-25 Author: Gregory R. Warnes, Ben Bolker, Gregor Gorjanc, Gabor Grothendieck, Ales Korosec, Thomas Lumley, Don MacQueen, Arni Magnusson, Jim Rogers, and others Modified: trunk/gdata/inst/ChangeLog =================================================================== --- trunk/gdata/inst/ChangeLog 2015-04-25 05:54:28 UTC (rev 1957) +++ trunk/gdata/inst/ChangeLog 2015-04-25 06:26:40 UTC (rev 1958) @@ -1,59 +1,101 @@ -2015-04-23 warnes +2015-04-23 22:49 warnes - * [r1952] R/write.fwf.R: - write.fwf() now properly supports - matrix objects, including matrix objects wihtout column - names. (Reported by Carl Witthoft.) - * [r1951] inst/perl/xls2csv.pl: Remove 'use POSIX' from xls2csv.pl - since it is no longer needed - * [r1939] inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog - * [r1938] R/reorder.R: reorder.factor() now hands off processing to + * inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog + +2015-04-23 22:41 warnes + + * R/write.fwf.R: - write.fwf() now properly supports matrix + objects, including matrix + objects wihtout column names. (Reported by Carl Witthoft.) + +2015-04-23 21:55 warnes + + * inst/perl/xls2csv.pl: Remove 'use POSIX' from xls2csv.pl since it + is no longer needed + +2015-04-23 17:40 warnes + + * inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog + +2015-04-23 17:37 warnes + + * R/reorder.R: reorder.factor() now hands off processing to stats:::reorder.default() when either 'X' or 'FUN' is specified. -2015-04-22 warnes +2015-04-22 23:18 warnes - * [r1937] inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog for - changes to humanReadable() - * [r1936] DESCRIPTION, R/humanReadable.R, R/object.size.R, + * inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog for changes + to humanReadable() + +2015-04-22 23:14 warnes + + * DESCRIPTION, R/humanReadable.R, R/object.size.R, man/humanReadable.Rd: Fix 'units' argument of humanReadable() - * [r1935] man/object.size.Rd: Update object.size() man page to - reflect change in class of return value from 'object_size' to + +2015-04-22 22:44 warnes + + * man/object.size.Rd: Update object.size() man page to reflect + change in class of return value from 'object_size' to 'object_sizes' - * [r1934] inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog for - gdata 2.16.0 - * [r1933] NAMESPACE, R/object.size.R: Modify gdaata:object.size to - generate S3 objects of class 'object_sizes' (note the final 's') - to avoid conflicts with methods in utils for object_size. - * [r1932] R/reorder.R, tests/test.reorder.factor.R, + +2015-04-22 22:41 warnes + + * inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog for gdata + 2.16.0 + +2015-04-22 22:34 warnes + + * NAMESPACE, R/object.size.R: Modify gdaata:object.size to generate + S3 objects of class 'object_sizes' (note the final 's') to avoid + conflicts with methods in utils for object_size. + +2015-04-22 22:32 warnes + + * R/reorder.R, tests/test.reorder.factor.R, tests/test.reorder.factor.Rout.save: Correct behavior of reorder.factor() when argument 'X' is supplied by delgating to stats:::reorder.default() -2015-04-14 warnes +2015-04-14 22:02 warnes - * [r1929] inst/ChangeLog: Update ChangeLog - * [r1928] man/write.fwf.Rd: Remove editorializing - * [r1927] inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog for - gdata 2.15.0 - * [r1926] R/write.fwf.R, man/write.fwf.Rd: Add 'scientific' - argument to write.fwf to allow control of whether numeric values - can be displated using scientific notation. - * [r1925] inst/perl/xls2csv.pl: Replace depricated PERL function - POSIX::isnumeric with equivalent regexp - * [r1924] inst/ChangeLog: Add gdata ChangeLog to SVN + * inst/ChangeLog: Update ChangeLog -2015-04-10 warnes +2015-04-14 22:02 warnes - * [r1922] DESCRIPTION, NAMESPACE, inst/NEWS: Update files for gdata + * man/write.fwf.Rd: Remove editorializing + +2015-04-14 21:55 warnes + + * inst/ChangeLog, inst/NEWS: Update NEWS and ChangeLog for gdata 2.15.0 -2015-04-08 warnes +2015-04-14 21:52 warnes - * [r1919] R/first.R, man/first.Rd, man/left.Rd: Move - first/last/left/right to from gtools to gdata + * R/write.fwf.R, man/write.fwf.Rd: Add 'scientific' argument to + write.fwf to allow control of whether numeric values can be + displated using scientific notation. -2014-08-28 warnes +2015-04-14 20:52 warnes - * [r1883] R/trim.R, inst/NEWS, inst/perl/xls2csv.pl, + * inst/perl/xls2csv.pl: Replace depricated PERL function + POSIX::isnumeric with equivalent regexp + +2015-04-14 19:43 warnes + + * inst/ChangeLog: Add gdata ChangeLog to SVN + +2015-04-10 03:15 warnes + + * DESCRIPTION, NAMESPACE, inst/NEWS: Update files for gdata 2.15.0 + +2015-04-08 19:55 warnes + + * R/first.R, man/first.Rd, man/left.Rd: Move first/last/left/right + to from gtools to gdata + +2014-08-28 15:01 warnes + + * R/trim.R, inst/NEWS, inst/perl/xls2csv.pl, inst/xls/ExampleExcelFile.xls, inst/xls/ExampleExcelFile.xlsx, inst/xls/ExampleExcelFile_1900.xls, inst/xls/ExampleExcelFile_1900.xlsx, @@ -61,36 +103,64 @@ inst/xls/ExampleExcelFile_1904.xlsx, tests/test.read.xls.R, tests/test.read.xls.Rout.save, tests/tests.write.fwf.Rout.save: Everything works now! - * [r1882] inst/perl/Spreadsheet/ParseExcel/FmtDefault.pm: Suppress - annoying warnings in Spreadsheet::ParseXLS::FmtDefalt. - * [r1881] inst/xls/ExampleExcelFile_1900.xls, + +2014-08-28 05:22 warnes + + * inst/perl/Spreadsheet/ParseExcel/FmtDefault.pm: Suppress annoying + warnings in Spreadsheet::ParseXLS::FmtDefalt. + +2014-08-28 05:17 warnes + + * inst/xls/ExampleExcelFile_1900.xls, inst/xls/ExampleExcelFile_1900.xlsx, inst/xls/ExampleExcelFile_1904.xls, inst/xls/ExampleExcelFile_1904.xlsx, tests/test.read.xls.R: Add tests and corresponding test files for 1900 and 1904 based XLX/XLSX files - * [r1880] inst/perl/Spreadsheet/XLSX, - inst/perl/Spreadsheet/XLSX.pm, inst/perl/install_modules.pl, - inst/perl/module_tools.pl, inst/perl/sheetCount.pl, - inst/perl/supportedFormats.pl: Complete transition from - Spreadsheet::XLSX to Spreadsheet::ParseXLSX - * [r1879] inst/perl/xls2csv.pl: Handle Excel files created on the - Mac, where by default Excel uses + +2014-08-28 04:56 warnes + + * inst/perl/Spreadsheet/XLSX, inst/perl/Spreadsheet/XLSX.pm, + inst/perl/install_modules.pl, inst/perl/module_tools.pl, + inst/perl/sheetCount.pl, inst/perl/supportedFormats.pl: Complete + transition from Spreadsheet::XLSX to Spreadsheet::ParseXLSX + +2014-08-28 04:55 warnes + + * inst/perl/xls2csv.pl: Handle Excel files created on the Mac, + where by default Excel uses 1904-01-01 as the baseline for dates, rather than the usual 1900-01-01. - * [r1878] inst/perl/Crypt/.exists, inst/perl/XML/.exists: Remove - dotfiles - * [r1877] DESCRIPTION, inst/NEWS: Update for release - * [r1876] inst/xls/wide.xls, inst/xls/wide.xlsx: Add test for - handling fo very wide xls and xlsx files. - * [r1875] tests/test.read.xls.R: Add test for handling fo very wide - xls and xlsx files. - * [r1874] inst/perl/module_tools.pl, inst/perl/sheetCount.pl, + +2014-08-28 03:08 warnes + + * inst/perl/Crypt/.exists, inst/perl/XML/.exists: Remove dotfiles + +2014-08-28 02:08 warnes + + * DESCRIPTION, inst/NEWS: Update for release + +2014-08-28 02:01 warnes + + * inst/xls/wide.xls, inst/xls/wide.xlsx: Add test for handling fo + very wide xls and xlsx files. + +2014-08-28 02:00 warnes + + * tests/test.read.xls.R: Add test for handling fo very wide xls and + xlsx files. + +2014-08-28 01:50 warnes + + * inst/perl/module_tools.pl, inst/perl/sheetCount.pl, inst/perl/xls2csv.pl: Modify code to use latest version of Spreadsheet::ParseExcel and to replace Spreadsheet::XLSX woth Spreadsheet::ParseXLSX - * [r1873] inst/perl/Crypt, inst/perl/Crypt/.exists, - inst/perl/Crypt/RC4.pm, inst/perl/Digest, inst/perl/Digest/Perl, + +2014-08-28 01:28 warnes + + * inst/perl/Crypt, inst/perl/Crypt/.exists, inst/perl/Crypt/RC4.pm, + inst/perl/Digest, inst/perl/Digest/Perl, inst/perl/Digest/Perl/MD5.pm, inst/perl/Graphics, inst/perl/Graphics/ColorUtils.pm, inst/perl/Spreadsheet/ParseExcel.pm, @@ -114,44 +184,93 @@ inst/perl/XML/Twig/XPath.pm: Update Spreadsheet::ParseExcel, add Spreadsheet:ParseXLSX, add dependencies -2014-04-05 warnes +2014-04-05 21:08 warnes - * [r1801] tests/unitTests/runit.unknown.R: Apply same changes to + * tests/unitTests/runit.unknown.R: Apply same changes to NAToUnknown that were previously applied to unknownToNA for POSIXlt. - * [r1800] inst/NEWS: Update NEWS with latest changes - * [r1799] R/nobs.R: Call stats::nobs instead of - stats:::nobs.default within + +2014-04-05 18:41 warnes + + * inst/NEWS: Update NEWS with latest changes + +2014-04-05 18:38 warnes + + * R/nobs.R: Call stats::nobs instead of stats:::nobs.default within gdata::nobs.default. This avoids R CMD check warning. - * [r1798] tests/unitTests/runit.unknown.R: Don't compare optional - POSIXlt field. Explicitly compare POSIXlt, with special handling - of '-1' unknown value. - * [r1797] R/mapLevels.R, R/unknown.R: Don't use gdata:::<foo> - prefix to access gdata function <foo> - * [r1796] DESCRIPTION: Fix syntax error in DESCRIPTION file. - * [r1795] tests/runRUnitTests.R: Package name needs to be defined - outside of if test. - * [r1794] vignettes/Rnews.sty: Style file needed - * [r1793] R/unknown.R, tests/unitTests/runit.unknown.R: The issue - Brian pointed out was an error in the isUnknown() code, not an - error in the unit tests! - * [r1792] tests/unitTests/runit.unknown.R: Apply changes Brian - recommned to NAtoUnknown as well as unknownToNA. - * [r1791] inst/NEWS: Update NEWS file - * [r1790] inst/doc/Rnews.dtx: Don't need latex .dtx source file - * [r1789] inst/doc/mapLevels.Rnw, inst/doc/unknown.Rnw, vignettes, + +2014-04-05 18:22 warnes + + * tests/unitTests/runit.unknown.R: Don't compare optional POSIXlt + field. Explicitly compare POSIXlt, with special handling of '-1' + unknown value. + +2014-04-05 18:19 warnes + + * R/mapLevels.R, R/unknown.R: Don't use gdata:::<foo> prefix to + access gdata function <foo> + +2014-04-05 17:01 warnes + + * DESCRIPTION: Fix syntax error in DESCRIPTION file. + +2014-04-05 17:00 warnes + + * tests/runRUnitTests.R: Package name needs to be defined outside + of if test. + +2014-04-05 17:00 warnes + + * vignettes/Rnews.sty: Style file needed + +2014-04-05 16:59 warnes + + * R/unknown.R, tests/unitTests/runit.unknown.R: The issue Brian + pointed out was an error in the isUnknown() code, not an error in + the unit tests! + +2014-04-05 15:55 warnes + + * tests/unitTests/runit.unknown.R: Apply changes Brian recommned to + NAtoUnknown as well as unknownToNA. + +2014-04-05 14:40 warnes + + * inst/NEWS: Update NEWS file + +2014-04-05 14:38 warnes + + * inst/doc/Rnews.dtx: Don't need latex .dtx source file + +2014-04-05 14:26 warnes + + * inst/doc/mapLevels.Rnw, inst/doc/unknown.Rnw, vignettes, vignettes/mapLevels.Rnw, vignettes/unknown.Rnw: Move vignettes from inst/doc/ to vignettes/ - * [r1788] R/aggregate.table.R, man/aggregate.table.Rd, + +2014-04-05 13:57 warnes + + * R/aggregate.table.R, man/aggregate.table.Rd, man/gdata-defunct.Rd: Change 'aggregate.table' from deprecated to defunct. - * [r1787] DESCRIPTION, inst/unitTests, man/gdata-package.Rd, + +2014-04-05 12:53 warnes + + * DESCRIPTION, inst/unitTests, man/gdata-package.Rd, tests/runRUnitTests.R, tests/unitTests: Complete changes so that the unit tests are run as part of R CMD check - * [r1786] DESCRIPTION, inst/NEWS: Update NEWS for gdata 2.13.4 - * [r1785] NAMESPACE: Update NAMESPACE file to remove deleted - function - * [r1784] inst/unitTests/Makefile, inst/unitTests/runit.bindData.R, + +2014-04-05 02:25 warnes + + * DESCRIPTION, inst/NEWS: Update NEWS for gdata 2.13.4 + +2014-04-05 02:25 warnes + + * NAMESPACE: Update NAMESPACE file to remove deleted function + +2014-04-05 02:23 warnes + + * inst/unitTests/Makefile, inst/unitTests/runit.bindData.R, inst/unitTests/runit.cbindX.R, inst/unitTests/runit.drop.levels.R, inst/unitTests/runit.getDateTimeParts.R, @@ -169,10 +288,16 @@ tests/runit.wideByFactor.R, tests/runit.write.fwf.R: Move unit test files back to inst/unitTests. Fix up runRUnitTests.R to work properly in the new location - * [r1783] tests/runit.unknown.R: - For unit tests, don't check for - equality of optional POSIXlt + +2014-04-05 01:27 warnes + + * tests/runit.unknown.R: - For unit tests, don't check for equality + of optional POSIXlt components. (Bug reported by Brian Ripley). - * [r1782] R/runRUnitTests.R, inst/unitTests/Makefile, + +2014-04-05 01:08 warnes + + * R/runRUnitTests.R, inst/unitTests/Makefile, inst/unitTests/runRUnitTests.R, inst/unitTests/runit.bindData.R, inst/unitTests/runit.cbindX.R, inst/unitTests/runit.drop.levels.R, @@ -191,80 +316,115 @@ tests/runit.wideByFactor.R, tests/runit.write.fwf.R: Move unit test code into the (now) standard location -2014-03-19 arnima +2014-03-19 10:04 arnima - * [r1777] R/keep.R: change warning message to R standards + * R/keep.R: change warning message to R standards -2013-12-18 arnima +2013-12-18 14:33 arnima - * [r1758] R/ll.R: Retain original list order unless sort=FALSE; - also stop if unnamed list + * R/ll.R: Retain original list order unless sort=FALSE; also stop + if unnamed list -2013-12-16 warnes +2013-12-16 19:58 warnes - * [r1757] R/trim.R: Trim will now remove all types of - leading/trailing whitespace by using + * R/trim.R: Trim will now remove all types of leading/trailing + whitespace by using the [:blank:] character class. -2013-06-29 warnes +2013-06-29 01:40 warnes - * [r1692] inst/NEWS: Update NEWS for second try for gdata 2.13.2 - * [r1691] R/ll.R: Simplify ll() by stuffing list arguments into an + * inst/NEWS: Update NEWS for second try for gdata 2.13.2 + +2013-06-29 01:37 warnes + + * R/ll.R: Simplify ll() by stuffing list arguments into an environment, avoiding the need to use attach/detach. -2013-06-28 warnes +2013-06-28 21:31 warnes - * [r1685] inst/NEWS: Update NEWS for gdata 2.13.2 - * [r1684] tests/test.read.xls.Rout.save, - tests/tests.write.fwf.Rout.save: Minor update to - tests/*.Rout.save - * [r1683] R/ll.R: Add on.exit() handler to ensure a matching detach - occurs when attach is used in ll() - * [r1682] DESCRIPTION: Update for gdata 2.13.2 - * [r1681] R/aggregate.table.R: Improve deprecated message + * inst/NEWS: Update NEWS for gdata 2.13.2 -2013-03-24 warnes +2013-06-28 21:24 warnes - * [r1645] tests/test.read.xls.Rout.save, - tests/tests.write.fwf.Rout.save: Update test files for code - changes - * [r1644] inst/NEWS: Fix formatting in NEWS - * [r1643] DESCRIPTION, inst/NEWS, man/read.xls.Rd, - man/sheetCount.Rd, tests/test.read.xls.R: Replaced calls to - depreciated function ".path.package" with the new public function - "path.package". + * tests/test.read.xls.Rout.save, tests/tests.write.fwf.Rout.save: + Minor update to tests/*.Rout.save -2013-01-14 warnes +2013-06-28 21:22 warnes - * [r1639] R/installXLSXsupport.R, R/sheetCount.R, R/xls2sep.R, + * R/ll.R: Add on.exit() handler to ensure a matching detach occurs + when attach is used in ll() + +2013-06-28 20:29 warnes + + * DESCRIPTION: Update for gdata 2.13.2 + +2013-06-28 20:26 warnes + + * R/aggregate.table.R: Improve deprecated message + +2013-03-24 04:50 warnes + + * tests/test.read.xls.Rout.save, tests/tests.write.fwf.Rout.save: + Update test files for code changes + +2013-03-24 04:36 warnes + + * inst/NEWS: Fix formatting in NEWS + +2013-03-24 04:34 warnes + + * DESCRIPTION, inst/NEWS, man/read.xls.Rd, man/sheetCount.Rd, + tests/test.read.xls.R: Replaced calls to depreciated function + ".path.package" with the new public function "path.package". + +2013-01-14 20:47 warnes + + * R/installXLSXsupport.R, R/sheetCount.R, R/xls2sep.R, R/xlsFormats.R: Replace (obsolete) '.path.package' with 'find.package' function. -2012-09-20 warnes +2012-09-20 17:35 warnes - * [r1622] man/MedUnits.Rd, man/ans.Rd, man/duplicated2.Rd: Correct - .Rd file errors detected by 'R CMD check'. - * [r1621] NAMESPACE: Add duplicated() and ans() to the NAMESPACE. - * [r1620] DESCRIPTION, inst/NEWS: Update for gdata 2.13.0. - * [r1619] man/ConvertMedUnits.Rd: Fix typographic error. - * [r1618] R/ans.R, R/duplicated2.R, man/ans.Rd, man/duplicated2.Rd: - Add 'ans()' and 'duplicated()' contributed by Liviu Andronic. + * man/MedUnits.Rd, man/ans.Rd, man/duplicated2.Rd: Correct .Rd file + errors detected by 'R CMD check'. -2012-09-19 warnes +2012-09-20 17:15 warnes - * [r1617] data/MedUnits.rda: Correct column names. Unit columns - were reversed and misspelled. - * [r1616] R/sheetCount.R: Add ignore.stderr to system command in - sheetCmd() to prevent stderr + * NAMESPACE: Add duplicated() and ans() to the NAMESPACE. + +2012-09-20 17:12 warnes + + * DESCRIPTION, inst/NEWS: Update for gdata 2.13.0. + +2012-09-20 15:42 warnes + + * man/ConvertMedUnits.Rd: Fix typographic error. + +2012-09-20 15:39 warnes + + * R/ans.R, R/duplicated2.R, man/ans.Rd, man/duplicated2.Rd: Add + 'ans()' and 'duplicated()' contributed by Liviu Andronic. + +2012-09-19 18:30 warnes + + * data/MedUnits.rda: Correct column names. Unit columns were + reversed and misspelled. + +2012-09-19 18:02 warnes + + * R/sheetCount.R: Add ignore.stderr to system command in sheetCmd() + to prevent stderr messages from being included in the captured output from the perl script. -2012-09-12 warnes +2012-09-12 17:40 warnes - * [r1606] DESCRIPTION, inst/NEWS: Update for gdata 2.12.0 - * [r1605] R/aggregate.table.R, man/aggregate.table.Rd: - 'stats::aggregate' was made into a generic on 27-Jan-2010, so - that + * DESCRIPTION, inst/NEWS: Update for gdata 2.12.0 + +2012-09-12 17:39 warnes + + * R/aggregate.table.R, man/aggregate.table.Rd: 'stats::aggregate' + was made into a generic on 27-Jan-2010, so that attempting to call 'aggregate' on a 'table' object will now incorrectly call 'aggregate.table'. Since 'aggregate.table' can be @@ -275,31 +435,48 @@ the 'aggregate.table' function will now display a warning that it is depreciated and recommending the equivalent call to tapply. It will be removed entirely in a future version of gdata. - * [r1604] .Rinstignore: Don't ignore .Rnw files, but do ignore .svn - files. -2012-09-11 warnes +2012-09-12 17:29 warnes - * [r1603] man/interleave.Rd: Clarify workding of DROP argument to + * .Rinstignore: Don't ignore .Rnw files, but do ignore .svn files. + +2012-09-11 20:41 warnes + + * man/interleave.Rd: Clarify workding of DROP argument to interleave(). - * [r1602] man/interleave.Rd: Replace call to aggregate.table() with + +2012-09-11 20:37 warnes + + * man/interleave.Rd: Replace call to aggregate.table() with equivalent tapply() call since aggregate.table() is being depreciated. -2012-08-22 warnes +2012-08-22 16:47 warnes - * [r1601] DESCRIPTION, inst/NEWS: Update DESCRIPTION and NEWS for - gdate 2.11.1. - * [r1600] man/read.xls.Rd: Add example for read.xls() that shows - how to use the fileEncoding + * DESCRIPTION, inst/NEWS: Update DESCRIPTION and NEWS for gdate + 2.11.1. + +2012-08-22 16:42 warnes + + * man/read.xls.Rd: Add example for read.xls() that shows how to use + the fileEncoding argument to read in latin-1 encoded data. - * [r1599] tests/latin-1.xls, tests/test.read.xls.R, + +2012-08-22 16:41 warnes + + * tests/latin-1.xls, tests/test.read.xls.R, tests/test.read.xls.Rout.save: Add XLSX test for latin-1 characters, and look for them in their new location in inst/xls/. - * [r1598] inst/xls/latin-1.xls, inst/xls/latin-1.xlsx: add XLSX - version of latin-1.xls - * [r1597] tests/latin-1.xls, tests/test.read.xls.R, + +2012-08-22 16:35 warnes + + * inst/xls/latin-1.xls, inst/xls/latin-1.xlsx: add XLSX version of + latin-1.xls + +2012-08-22 15:48 warnes + + * tests/latin-1.xls, tests/test.read.xls.R, tests/test.read.xls.Rout.save: Add test file and code to ensure that read.xls() can properly handle files with alternative encodings. latin-1.xls contains each of @@ -307,23 +484,34 @@ non-ascii latin-1 special characters in both the column headings and the body of the file. - * [r1596] R/read.xls.R: Change code to have R read the csv/tab data - from the file rather than + +2012-08-22 15:45 warnes + + * R/read.xls.R: Change code to have R read the csv/tab data from + the file rather than from the connetion we made, so that file encodings can be properly handled. - * [r1595] R/read.xls.R: Always close the connection. -2012-08-13 warnes +2012-08-22 14:29 warnes - * [r1594] inst/perl/xls2csv.pl: Remove trailing space from output - line. + * R/read.xls.R: Always close the connection. -2012-06-18 warnes +2012-08-13 22:13 warnes - * [r1567] inst/NEWS: Update NEWS for 2.11.0 release. - * [r1566] DESCRIPTION: Bump version number and add - SystemRequirements for perl. - * [r1565] R/xls2sep.R, inst/perl/xls2csv.pl, man/read.xls.Rd, + * inst/perl/xls2csv.pl: Remove trailing space from output line. + +2012-06-18 20:32 warnes + + * inst/NEWS: Update NEWS for 2.11.0 release. + +2012-06-18 20:27 warnes + + * DESCRIPTION: Bump version number and add SystemRequirements for + perl. + +2012-06-18 20:26 warnes + + * R/xls2sep.R, inst/perl/xls2csv.pl, man/read.xls.Rd, tests/test.read.xls.R, tests/test.read.xls.Rout.save: read.xls() and supporting functions now allow blank lines to be preserved, rather than skipped, by supplying the argument @@ -331,180 +519,274 @@ extended to suppor this via an optional "-s" argument which, when present, *preserves* blank lines during the conversion. -2012-06-13 warnes +2012-06-13 01:10 warnes - * [r1564] DESCRIPTION, R/nobs.R, inst/NEWS: - nobs.default needs to - handle logical vectors in addition to numeric + * DESCRIPTION, R/nobs.R, inst/NEWS: - nobs.default needs to handle + logical vectors in addition to numeric vectors. - update DESCRIPTION and NEWS for 2.10.6. - * [r1563] R/nobs.R: nobs.default needs to handle logical as well as - numeric vectors. -2012-06-08 warnes +2012-06-13 01:00 warnes - * [r1562] DESCRIPTION, tests/test.read.xls.Rout.save: Update - DESCRIPTION and tests - * [r1561] tests/test.read.xls.R: fix incorrect function name - * [r1560] DESCRIPTION, man/installXLSXsupport.Rd: Mark example for + * R/nobs.R: nobs.default needs to handle logical as well as numeric + vectors. + +2012-06-08 22:04 warnes + + * DESCRIPTION, tests/test.read.xls.Rout.save: Update DESCRIPTION + and tests + +2012-06-08 21:59 warnes + + * tests/test.read.xls.R: fix incorrect function name + +2012-06-08 20:02 warnes + + * DESCRIPTION, man/installXLSXsupport.Rd: Mark example for installXLSXsupport() to not be executed durin R CMD check. - * [r1559] DESCRIPTION: stats:::nobs.default and stats::nobs.lm - require R > 2.13.0, so add this as a dependency. -2012-06-06 warnes +2012-06-08 19:01 warnes - * [r1552] DESCRIPTION, inst/NEWS: Update for release 2.10.2 - * [r1551] R/nobs.R: Fix bugs in nobs.default. - * [r1550] tests/test.read.xls.Rout.save, - tests/tests.write.fwf.Rout.save: Update to reflect warning on - startup that 'nobs' hides 'stats::nobs'. - * [r1549] man/nobs.Rd: Remove stray non-ASCII characters. - * [r1548] R/nobs.R: The nobs() dispatch method must be defined in - the gdata namespace to + * DESCRIPTION: stats:::nobs.default and stats::nobs.lm require R > + 2.13.0, so add this as a dependency. + +2012-06-06 22:10 warnes + + * DESCRIPTION, inst/NEWS: Update for release 2.10.2 + +2012-06-06 22:09 warnes + + * R/nobs.R: Fix bugs in nobs.default. + +2012-06-06 21:11 warnes + + * tests/test.read.xls.Rout.save, tests/tests.write.fwf.Rout.save: + Update to reflect warning on startup that 'nobs' hides + 'stats::nobs'. + +2012-06-06 21:11 warnes + + * man/nobs.Rd: Remove stray non-ASCII characters. + +2012-06-06 21:07 warnes + + * R/nobs.R: The nobs() dispatch method must be defined in the gdata + namespace to pick up the definition of gdata::nobs.default. - * [r1547] DESCRIPTION, inst/NEWS: Update DESCRIPTION and NEWS for - 2.10.1 release. - * [r1546] NAMESPACE, R/nobs.R, man/nobs.Rd: Define aliases for - 'nobs' and 'nobs.lm' to support backward + +2012-06-06 20:30 warnes + + * DESCRIPTION, inst/NEWS: Update DESCRIPTION and NEWS for 2.10.1 + release. + +2012-06-06 20:26 warnes + + * NAMESPACE, R/nobs.R, man/nobs.Rd: Define aliases for 'nobs' and + 'nobs.lm' to support backward compatibility for packages depending on gdata. - * [r1545] DESCRIPTION, inst/NEWS: Update DESCRIPTION and NEWS for - 2.10.0 release - * [r1544] NAMESPACE, R/startsWith.R, man/startsWith.Rd: - Add - manual page and NAMESPACE entry for startsWith(). + +2012-06-06 01:59 warnes + + * DESCRIPTION, inst/NEWS: Update DESCRIPTION and NEWS for 2.10.0 + release + +2012-06-06 01:53 warnes + + * NAMESPACE, R/startsWith.R, man/startsWith.Rd: - Add manual page + and NAMESPACE entry for startsWith(). - Add 'ignore.case' argument to startsWith(). - * [r1543] tests/test.read.xls.Rout.save: Update to match new code. - * [r1542] man/read.xls.Rd: Replace non-ASCII characters. - * [r1541] R/read.xls.R, man/read.xls.Rd, tests/test.read.xls.R: Add + +2012-06-06 01:26 warnes + + * tests/test.read.xls.Rout.save: Update to match new code. + +2012-06-06 01:25 warnes + + * man/read.xls.Rd: Replace non-ASCII characters. + +2012-06-06 01:21 warnes + + * R/read.xls.R, man/read.xls.Rd, tests/test.read.xls.R: Add na.strings to read.xls call to convert "#DIV/0!" to NA. -2012-06-05 warnes +2012-06-05 20:09 warnes - * [r1540] NAMESPACE: Remove nobs method dispatch and lm methods - since these are now provided by the stats package. - * [r1539] R/env.R: Spell out arguments to ls() to avoid R CMD check + * NAMESPACE: Remove nobs method dispatch and lm methods since these + are now provided by the stats package. + +2012-06-05 20:08 warnes + + * R/env.R: Spell out arguments to ls() to avoid R CMD check warnings. - * [r1538] .Rinstignore: Add .Rinstignore file to omit latex style - and source files from distributed inst/doc directory. - * [r1537] R/ConvertMedUnits.R: - Add NULL definition of MedUnits to - avoid R CMD check warning. + +2012-06-05 20:08 warnes + + * .Rinstignore: Add .Rinstignore file to omit latex style and + source files from distributed inst/doc directory. + +2012-06-05 19:56 warnes + + * R/ConvertMedUnits.R: - Add NULL definition of MedUnits to avoid R + CMD check warning. - Specify local environment when calling data() so that MedUnits gets defined in the function's environment rather than the global environment. - * [r1536] R/ls.funs.R: Fix error in ls.funs() that occurs when - there are no objects in the environment. - * [r1535] R/object.size.R: Avoid warning by calling - utils::object.size rather than Internal(object.size(x)) -2012-05-31 warnes +2012-06-05 19:07 warnes - * [r1534] R/nobs.R, man/nobs.Rd: - Remove dispatch function 'nobs' - and method 'nobs.lm' since these are + * R/ls.funs.R: Fix error in ls.funs() that occurs when there are no + objects in the environment. + +2012-06-05 18:36 warnes + + * R/object.size.R: Avoid warning by calling utils::object.size + rather than Internal(object.size(x)) + +2012-05-31 22:14 warnes + + * R/nobs.R, man/nobs.Rd: - Remove dispatch function 'nobs' and + method 'nobs.lm' since these are now provided by the R 'stats' package. -2012-05-04 warnes +2012-05-04 21:20 warnes - * [r1532] DESCRIPTION: Update for next release - * [r1531] NAMESPACE, R/ls.funs.R, man/ls.funs.Rd: Add ls.funs() to - show functions defined in the specified environment. - * [r1530] man/is.what.Rd: Fix enumerate syntax. + * DESCRIPTION: Update for next release -2012-04-03 warnes +2012-05-04 19:39 warnes - * [r1522] R/startsWith.R: Add startsWith() function. + * NAMESPACE, R/ls.funs.R, man/ls.funs.Rd: Add ls.funs() to show + functions defined in the specified environment. -2011-10-05 warnes +2012-05-04 19:38 warnes - * [r1516] man/read.xls.Rd: Fix typo + * man/is.what.Rd: Fix enumerate syntax. -2011-09-30 warnes +2012-04-03 19:49 warnes - * [r1515] inst/NEWS: Update DESCRIPTION and README for 2.9.0 - release. - * [r1514] DESCRIPTION: Update DESCRIPTION and README for 2.9.0 - release. + * R/startsWith.R: Add startsWith() function. -2011-09-20 warnes +2011-10-05 15:31 warnes - * [r1508] man/read.xls.Rd: Improve xls2csv() man page - * [r1507] NAMESPACE: Add case() function, a vector equivalent of - the switch() function - * [r1506] R/case.R, man/case.Rd: Add case() function, a vector - equivalent of the switch() function + * man/read.xls.Rd: Fix typo -2011-09-02 warnes +2011-09-30 19:09 warnes - * [r1500] NAMESPACE: Add 'centerText' function to center text - strings for a specified width. - * [r1499] R/centerText.R, man/centerText.Rd: Add 'centerText' - function to center text strings for a specified width. + * inst/NEWS: Update DESCRIPTION and README for 2.9.0 release. -2011-04-16 warnes +2011-09-30 19:09 warnes - * [r1469] DESCRIPTION, inst/NEWS: Update for release 2.8.2 + * DESCRIPTION: Update DESCRIPTION and README for 2.9.0 release. -2011-04-15 warnes +2011-09-20 18:08 warnes - * [r1468] R/dQuote.ascii.R, R/installXLSXsupport.R, R/read.xls.R, + * man/read.xls.Rd: Improve xls2csv() man page + +2011-09-20 18:07 warnes + + * NAMESPACE: Add case() function, a vector equivalent of the + switch() function + +2011-09-20 18:07 warnes + + * R/case.R, man/case.Rd: Add case() function, a vector equivalent + of the switch() function + +2011-09-02 17:25 warnes + + * NAMESPACE: Add 'centerText' function to center text strings for a + specified width. + +2011-09-02 17:24 warnes + + * R/centerText.R, man/centerText.Rd: Add 'centerText' function to + center text strings for a specified width. + +2011-04-16 17:04 warnes + + * DESCRIPTION, inst/NEWS: Update for release 2.8.2 + +2011-04-15 20:25 warnes + + * R/dQuote.ascii.R, R/installXLSXsupport.R, R/read.xls.R, R/sheetCount.R, R/xls2sep.R: Fix errors on windows when R or Perl install path includes spaces by properly quoting the path. - * [r1467] R/xlsFormats.R: Fix error in xlsFormat() on windows when - R or Perl install path includes spaces by quoting the path. -2011-01-15 ggorjan +2011-04-15 19:43 warnes - * [r1465] NAMESPACE, R/nPairs.R, inst/NEWS, - inst/unitTests/runit.nPairs.R, man/nPairs.Rd: Adding summary - method for nPairs + * R/xlsFormats.R: Fix error in xlsFormat() on windows when R or + Perl install path includes spaces by quoting the path. -2010-11-12 warnes +2011-01-15 21:58 ggorjan - * [r1462] inst/NEWS: Update NEWS for gdata 2.8.1 - * [r1461] DESCRIPTION: Update DEScription file for 2.8.1 release - * [r1460] tests/test.read.xls.Rout.save, - tests/tests.write.fwf.Rout.save: Update test output to match - latest code - * [r1459] R/write.fwf.R, man/write.fwf.Rd, - tests/test.write.fwf.eol.R: Modify write.fwf() to capture and - pass on additional arguments for + * NAMESPACE, R/nPairs.R, inst/NEWS, inst/unitTests/runit.nPairs.R, + man/nPairs.Rd: Adding summary method for nPairs + +2010-11-12 19:14 warnes + + * inst/NEWS: Update NEWS for gdata 2.8.1 + +2010-11-12 19:09 warnes + + * DESCRIPTION: Update DEScription file for 2.8.1 release + +2010-11-12 19:08 warnes + + * tests/test.read.xls.Rout.save, tests/tests.write.fwf.Rout.save: + Update test output to match latest code + +2010-11-12 19:08 warnes + + * R/write.fwf.R, man/write.fwf.Rd, tests/test.write.fwf.eol.R: + Modify write.fwf() to capture and pass on additional arguments + for write.table(). This resolves a bug reported by Jan Wijffels. -2010-11-01 arnima +2010-11-01 00:30 arnima - * [r1453] man/Args.Rd: Minor improvement in Args.Rd help page + * man/Args.Rd: Minor improvement in Args.Rd help page -2010-10-19 warnes +2010-10-19 22:04 warnes - * [r1452] R/onAttach.R, R/xls2sep.R: Avoid use of file.access() - which is unreliable on Windows network shares. + * R/onAttach.R, R/xls2sep.R: Avoid use of file.access() which is + unreliable on Windows network shares. -2010-07-08 ggrothendieck2 +2010-07-08 12:36 ggrothendieck2 - * [r1448] R/xls2sep.R: findPerl call added to xls2sep + * R/xls2sep.R: findPerl call added to xls2sep -2010-07-07 ggrothendieck2 +2010-07-07 22:48 ggrothendieck2 - * [r1447] man/read.xls.Rd: small improvements to read.xls.Rd + * man/read.xls.Rd: small improvements to read.xls.Rd -2010-05-03 warnes +2010-05-03 16:26 warnes - * [r1439] NAMESPACE, R/installXLSXModules.R, - R/installXLSXsupport.R, R/onAttach.R, inst/NEWS, - man/installXLSXsupport.Rd, man/xlsFormats.Rd: Rename - installXLSXModules() to installXLSXsupport() and provide - documentation for it. - * [r1438] inst/NEWS: Update news for gdata 2.8.0 - * [r1437] DESCRIPTION, NAMESPACE, R/installXLSXModules.R, - R/onAttach.R, inst/perl/install_modules.pl, - inst/perl/module_tools.pl, tests/test.read.xls.R: Add .onAttach - function to check & inform user if perl is available, to check - whether XLS and XLSX formats are avaiable, and to run the (new) - installXLSXModules() functon to attempt to install the necessar - libraries if not. Added installXLSXModules() function. + * NAMESPACE, R/installXLSXModules.R, R/installXLSXsupport.R, + R/onAttach.R, inst/NEWS, man/installXLSXsupport.Rd, + man/xlsFormats.Rd: Rename installXLSXModules() to + installXLSXsupport() and provide documentation for it. -2010-05-02 warnes +2010-05-03 13:48 warnes - * [r1436] man/xlsFormats.Rd: Correct error in xlsFormat example - * [r1435] DESCRIPTION, NAMESPACE, R/dQuote.ascii.R, R/findPerl.R, + * inst/NEWS: Update news for gdata 2.8.0 + +2010-05-03 13:35 warnes + + * DESCRIPTION, NAMESPACE, R/installXLSXModules.R, R/onAttach.R, + inst/perl/install_modules.pl, inst/perl/module_tools.pl, + tests/test.read.xls.R: Add .onAttach function to check & inform + user if perl is available, to check whether XLS and XLSX formats + are avaiable, and to run the (new) installXLSXModules() functon + to attempt to install the necessar libraries if not. Added + installXLSXModules() function. + +2010-05-02 13:56 warnes + + * man/xlsFormats.Rd: Correct error in xlsFormat example + +2010-05-02 06:11 warnes + + * DESCRIPTION, NAMESPACE, R/dQuote.ascii.R, R/findPerl.R, R/read.xls.R, R/xlsFormats.R, inst/doc/gregmisc.tex, inst/perl/install_modules.pl, inst/perl/module_tools.pl, inst/perl/sheetCount.pl, inst/perl/supportedFormats.pl, @@ -519,71 +801,121 @@ generate warnings) when Zlib or SpreadSheet::XLXS is not instaled. Also update Greg's email address -2010-02-21 ggrothendieck2 +2010-02-21 17:12 ggrothendieck2 - * [r1423] R/read.xls.R, man/read.xls.Rd: isOpen problems fixed - (isOpen must have changed in R since this worked in earlier - versions). Also nba.xls link in read.xls.Rd disappeared. Replaced - with similar link. + * R/read.xls.R, man/read.xls.Rd: isOpen problems fixed (isOpen must + have changed in R since this worked in earlier versions). Also + nba.xls link in read.xls.Rd disappeared. Replaced with similar + link. -2010-02-20 ggrothendieck2 +2010-02-20 11:32 ggrothendieck2 - * [r1422] INSTALL: improved INSTALL file + * INSTALL: improved INSTALL file -2010-02-19 ggrothendieck2 +2010-02-19 15:36 ggrothendieck2 - * [r1421] INSTALL, R/dQuote.ascii.R, R/read.xls.R, R/sheetCount.R, + * INSTALL, R/dQuote.ascii.R, R/read.xls.R, R/sheetCount.R, inst/NEWS: added findPerl to locate ActiveState Perl on Windows if perl= not specified and Rtools perl would have otherwise been used. Also added INSTALL file. -2010-01-28 warnes +2010-01-28 19:58 warnes - * [r1419] DESCRIPTION, inst/NEWS: Update for release 2.7.1 - * [r1418] R/xls2sep.R: xls2sep(): Show output of perl call when - verbose=T - * [r1417] src/build.bat: More Win32 fixes - * [r1416] src/Makefile, src/Makefile.win, src/build.bat: More work - on Win32 building - * [r1415] src/Makefile, src/Makefile.win, src/build.bat: Support - building Compress::Raw::Zlib perl package under windows. + * DESCRIPTION, inst/NEWS: Update for release 2.7.1 -2010-01-26 warnes +2010-01-28 19:56 warnes - * [r1413] inst/NEWS: Fix typos - * [r1412] R/sheetCount.R: Show more details in sheetCount() when + * R/xls2sep.R: xls2sep(): Show output of perl call when verbose=T + +2010-01-28 16:43 warnes + + * src/build.bat: More Win32 fixes + +2010-01-28 16:00 warnes + + * src/Makefile, src/Makefile.win, src/build.bat: More work on Win32 + building + +2010-01-28 03:58 warnes + + * src/Makefile, src/Makefile.win, src/build.bat: Support building + Compress::Raw::Zlib perl package under windows. + +2010-01-26 04:12 warnes + + * inst/NEWS: Fix typos + +2010-01-26 04:11 warnes + + * R/sheetCount.R: Show more details in sheetCount() when verbose=TRUE -2010-01-24 warnes +2010-01-24 23:30 warnes - * [r1411] R/xls2sep.R: Replace two calls to 'dQuote', to - 'dQuote.ascii' - * [r1408] inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: Remove + * R/xls2sep.R: Replace two calls to 'dQuote', to 'dQuote.ascii' + +2010-01-24 19:25 warnes + + * inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: Remove auto-generated pdf files from svn - * [r1407] src/Makefile: create 'distclean' to remove perl binary - dir, currently mac-only - * [r1406] R/read.xls.R, R/xls2sep.R: Make read.xls() and xls2sep() - quieter when verbose=FALSE - * [r1405] tests/test.read.xls.R, tests/test.read.xls.Rout.save: Add - tests for read.xls, sheetCount, and sheetNames - * [r1404] src/Makefile: Modify makefile to 1) clean up after build, - 2) make tar non-verbose - * [r1403] R/read.xls.R, R/sheetCount.R: Close connections when - done. - * [r1402] man/read.xls.Rd: Fix typo - * [r1401] man/read.xls.Rd, man/sheetNames.Rd: Fix R CMD CHECK - errors - * [r1400] src/Compress-Raw-Zlib-2.024, - src/Compress-Raw-Zlib-2.024.tar.gz, src/Makefile: Use the - original gz file for Compress::Raw::Zlib to avoid issues with - 'non-platform-independent' filename error in R CMD CHECK - * [r1399] inst/perl/Archive/README-Archive-Zip, + +2010-01-24 19:18 warnes + + * src/Makefile: create 'distclean' to remove perl binary dir, + currently mac-only + +2010-01-24 19:13 warnes + + * R/read.xls.R, R/xls2sep.R: Make read.xls() and xls2sep() quieter + when verbose=FALSE + +2010-01-24 19:12 warnes + + * tests/test.read.xls.R, tests/test.read.xls.Rout.save: Add tests + for read.xls, sheetCount, and sheetNames + +2010-01-24 18:22 warnes + + * src/Makefile: Modify makefile to 1) clean up after build, 2) make + tar non-verbose + +2010-01-24 18:19 warnes + + * R/read.xls.R, R/sheetCount.R: Close connections when done. + +2010-01-24 18:17 warnes + + * man/read.xls.Rd: Fix typo + +2010-01-24 18:10 warnes + + * man/read.xls.Rd, man/sheetNames.Rd: Fix R CMD CHECK errors + +2010-01-24 08:47 warnes + + * src/Compress-Raw-Zlib-2.024, src/Compress-Raw-Zlib-2.024.tar.gz, + src/Makefile: Use the original gz file for Compress::Raw::Zlib to + avoid issues with 'non-platform-independent' filename error in R + CMD CHECK + +2010-01-24 08:38 warnes + + * inst/perl/Archive/README-Archive-Zip, inst/perl/Archive/README-Archive::Zip: Rename files to remove R CMD check error - * [r1398] DESCRIPTION, inst/NEWS, inst/doc/mapLevels.pdf, + +2010-01-24 08:33 warnes + + * DESCRIPTION, inst/NEWS, inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: Update for 2.7.0 release - * [r1397] NAMESPACE: Add new functions to NAMESPACE - * [r1396] src, src/Compress-Raw-Zlib-2.024, + +2010-01-24 08:21 warnes + + * NAMESPACE: Add new functions to NAMESPACE + +2010-01-24 08:19 warnes + + * src, src/Compress-Raw-Zlib-2.024, src/Compress-Raw-Zlib-2.024/Changes, src/Compress-Raw-Zlib-2.024/MANIFEST, src/Compress-Raw-Zlib-2.024/META.yml, @@ -644,18 +976,35 @@ src/Compress-Raw-Zlib-2.024/zlib-src/zutil.c, src/Compress-Raw-Zlib-2.024/zlib-src/zutil.h, src/Makefile: Add Compress::Raw::Zlib code - * [r1395] man/read.xls.Rd, man/sheetCount.Rd: Add/Update - documentation - * [r1394] R/xls2sep.R: Minor formatting change - * [r1393] inst/xls/ExampleExcelFile.xls, - inst/xls/ExampleExcelFile.xlsx: Add additional example files - * [r1392] inst/perl/sheetCount.pl, inst/perl/sheetNames.pl, + +2010-01-24 08:15 warnes + + * man/read.xls.Rd, man/sheetCount.Rd: Add/Update documentation + +2010-01-24 08:06 warnes + + * R/xls2sep.R: Minor formatting change + +2010-01-24 07:54 warnes + + * inst/xls/ExampleExcelFile.xls, inst/xls/ExampleExcelFile.xlsx: + Add additional example files + +2010-01-24 07:49 warnes + + * inst/perl/sheetCount.pl, inst/perl/sheetNames.pl, inst/perl/xls2csv.pl: Combine sheetCount.pl and sheetNames.pl and modify to support Excel 2007 'xlsx' format - * [r1391] inst/perl/Spreadsheet/XLSX.pm, + +2010-01-24 07:26 warnes + + * inst/perl/Spreadsheet/XLSX.pm, inst/perl/Spreadsheet/XLSX/Fmt2007.pm, inst/perl/xls2csv.pl: Complete changes to handle Excel 2007 'xlsx' files - * [r1390] inst/perl/Archive, inst/perl/Archive/README-Archive::Zip, + +2010-01-24 05:36 warnes + + * inst/perl/Archive, inst/perl/Archive/README-Archive::Zip, inst/perl/Archive/Zip, inst/perl/Archive/Zip.pm, inst/perl/Archive/Zip/Archive.pm, inst/perl/Archive/Zip/BufferedFileHandle.pm, @@ -677,40 +1026,67 @@ inst/perl/Spreadsheet/XLSX/Utility2007.pm, inst/perl/VERSIONS: Add additional Perl modules to support Excel 2007 'xlsx' files -2010-01-24 ggrothendieck2 +2010-01-24 02:28 ggrothendieck2 - * [r1389] NAMESPACE, man/sheetNames.Rd: added sheetNames.Rd - (documenting sheetNames/sheetCount) and updated NAMESPACE file. - * [r1388] inst/NEWS: fixed spacing problem in NEWS + * NAMESPACE, man/sheetNames.Rd: added sheetNames.Rd (documenting + sheetNames/sheetCount) and updated NAMESPACE file. -2010-01-23 warnes +2010-01-24 02:05 ggrothendieck2 - * [r1387] inst/perl/xls2csv.pl: Check if parsing the xls file - succeeds... Current code doesn't handle new XML-based format - * [r1386] inst/perl/Spreadsheet/XLSX: Remove perl - 'Spreadsheet:XLSX' module since it depends on Compress-Raw-Zlib, - which probably won't be available on most machines, and I don't - have time to figure out how to get R to build it properly when - gdata is installed. - * [r1385] inst/perl/Spreadsheet/XLSX, + * inst/NEWS: fixed spacing problem in NEWS + +2010-01-23 07:11 warnes + + * inst/perl/xls2csv.pl: Check if parsing the xls file succeeds... + Current code doesn't handle new XML-based format + +2010-01-23 07:09 warnes + + * inst/perl/Spreadsheet/XLSX: Remove perl 'Spreadsheet:XLSX' module + since it depends on Compress-Raw-Zlib, which probably won't be + available on most machines, and I don't have time to figure out + how to get R to build it properly when gdata is installed. + +2010-01-23 06:49 warnes + + * inst/perl/Spreadsheet/XLSX, inst/perl/Spreadsheet/XLSX/Fmt2007.pm, inst/perl/Spreadsheet/XLSX/Utility2007.pm: Add perl 'Spreadsheet:XLSX' module to support new Excel XML format files - * [r1384] R/xls2sep.R: Add xls2tsv() convenience wrapper to - xls2sep() - * [r1383] R/read.xls.R, R/xls2sep.R: Update to match new xls2csv.pl - code, allow specification of sheets by name, support CSV and TAB + +2010-01-23 05:51 warnes + + * R/xls2sep.R: Add xls2tsv() convenience wrapper to xls2sep() + +2010-01-23 05:50 warnes + + * R/read.xls.R, R/xls2sep.R: Update to match new xls2csv.pl code, + allow specification of sheets by name, support CSV and TAB delimited files using the same code, other minor changes. - * [r1382] R/sheetCount.R: Add sheetNames() function to extract the - names from XLS files - * [r1381] inst/bin/xls2csv.bat: Fix xls2csv.bat - * [r1380] inst/perl/xls2csv.pl: If only one sheet is present in the - file, don't insert the sheet name into the filename - * [r1379] inst/xls/ExampleExcelFile.xls, - inst/xls/ExampleExcelFile.xlsx: Add additional test/example Excel - files - * [r1378] inst/perl/xls2csv.pl, inst/perl/xls2tab.pl, - inst/perl/xls2tsv.pl: Modify xls2csv.pl script to: + +2010-01-23 05:45 warnes + + * R/sheetCount.R: Add sheetNames() function to extract the names + from XLS files + +2010-01-23 05:23 warnes + + * inst/bin/xls2csv.bat: Fix xls2csv.bat + +2010-01-23 05:17 warnes + + * inst/perl/xls2csv.pl: If only one sheet is present in the file, + don't insert the sheet name into the filename + +2010-01-23 04:38 warnes + + * inst/xls/ExampleExcelFile.xls, inst/xls/ExampleExcelFile.xlsx: + Add additional test/example Excel files + +2010-01-23 04:34 warnes + + * inst/perl/xls2csv.pl, inst/perl/xls2tab.pl, inst/perl/xls2tsv.pl: + Modify xls2csv.pl script to: - Use tab-delimiter and .tsv or .tab extension if called with the name xls2tsv.pl or xls2tab.pl, respectively. This allows a single @@ -720,15 +1096,21 @@ - Allow selection of sheets by name - Provide better error checking - Other code improvements - * [r1377] inst/perl/sheetCount.pl, inst/perl/sheetNames.pl: Add - perl scripts to extract worksheet names and sheet count from - Excel files -2010-01-22 warnes +2010-01-23 02:30 warnes - * [r1376] inst/perl/OLE/Storage_Lite.pm: Upgrade Perl - OLE::StorageLight module to version 0.19 - * [r1375] inst/perl/Spreadsheet/ParseExcel.pm, + * inst/perl/sheetCount.pl, inst/perl/sheetNames.pl: Add perl + scripts to extract worksheet names and sheet count from Excel + files + +2010-01-22 19:35 warnes + + * inst/perl/OLE/Storage_Lite.pm: Upgrade Perl OLE::StorageLight + module to version 0.19 + +2010-01-22 19:31 warnes + + * inst/perl/Spreadsheet/ParseExcel.pm, inst/perl/Spreadsheet/ParseExcel/Cell.pm, inst/perl/Spreadsheet/ParseExcel/Dump.pm, inst/perl/Spreadsheet/ParseExcel/FmtDefault.pm, @@ -745,20 +1127,25 @@ inst/perl/Spreadsheet/ParseExcel/Workbook.pm, inst/perl/Spreadsheet/ParseExcel/Worksheet.pm: Upgrade perl Spreadsheet::ParseExcel to version 0.56 - * [r1374] DESCRIPTION: Add complete list of contributors -2010-01-22 arnima +2010-01-22 19:20 warnes - * [r1373] man/keep.Rd: Minor improvement in help page - * [r1371] R/Args.R, R/env.R, R/is.what.R, R/keep.R, R/ll.R, - man/Args.Rd, man/env.Rd, man/is.what.Rd, man/keep.Rd, man/ll.Rd: - Many small improvements to documentation of Arni's five functions + * DESCRIPTION: Add complete list of contributors -2010-01-22 warnes +2010-01-22 14:00 arnima - * [r1370] R/dQuote.ascii.R, R/read.xls.R, R/sheetCount.R, - R/xls2sep.R: - Move xls2csv(), xls2tab(), xls2sep() to a separate - file + * man/keep.Rd: Minor improvement in help page + +2010-01-22 13:06 arnima + + * R/Args.R, R/env.R, R/is.what.R, R/keep.R, R/ll.R, man/Args.Rd, + man/env.Rd, man/is.what.Rd, man/keep.Rd, man/ll.Rd: Many small + improvements to documentation of Arni's five functions + +2010-01-22 12:45 warnes + + * R/dQuote.ascii.R, R/read.xls.R, R/sheetCount.R, R/xls2sep.R: - + Move xls2csv(), xls2tab(), xls2sep() to a separate file - Move qQuote.ascii to a separate file - Bug Fix: xls2csv(), xls2tab() failed to pass the provided @@ -769,111 +1156,157 @@ read.xls) now supports ftp URLs. -2009-12-06 arnima +2009-12-06 22:34 arnima - * [r1369] R/Args.R, man/Args.Rd: Minor improvements of Args(). - * [r1368] R/ll.R, man/ll.Rd: Improved ll() so user can limit output - to specified classes + * R/Args.R, man/Args.Rd: Minor improvements of Args(). -2009-11-16 arnima +2009-12-06 03:12 arnima - * [r1366] R/ll.R: ll(.GlobalEnv) does not crash anymore + * R/ll.R, man/ll.Rd: Improved ll() so user can limit output to + specified classes -2009-08-20 warnes +2009-11-16 12:57 arnima - * [r1357] man/cbindX.Rd, man/getDateTimePart.Rd, man/mapLevels.Rd, + * R/ll.R: ll(.GlobalEnv) does not crash anymore + +2009-08-20 14:54 warnes + + * man/cbindX.Rd, man/getDateTimePart.Rd, man/mapLevels.Rd, man/nPairs.Rd, man/trim.Rd, man/trimSum.Rd, man/unknown.Rd, man/write.fwf.Rd: Replace \ldots with \dots to make the new R CMD CHECK happy. -2009-08-19 warnes +2009-08-19 17:39 warnes - * [r1355] DESCRIPTION: Update for 2.6.1 release - * [r1354] inst/unitTests/runit.getDateTimeParts.R: Modify unit - tests to avoid issues related to zime zones. + * DESCRIPTION: Update for 2.6.1 release -2009-08-05 warnes +2009-08-19 17:37 warnes - * [r1353] inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: Update - vignettes for 2.6.0 release - * [r1352] man/frameApply.Rd: Fix formatting warning in frameApply - man page + * inst/unitTests/runit.getDateTimeParts.R: Modify unit tests to + avoid issues related to zime zones. -2009-07-16 ggorjan +2009-08-05 01:57 warnes - * [r1350] man/write.fwf.Rd: Reverting recent change and clarifying - the meaning. + * inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: Update vignettes + for 2.6.0 release -2009-07-16 warnes +2009-08-05 01:57 warnes - * [r1349] inst/doc/mapLevels.pdf, inst/doc/unknown.pdf, - man/resample.Rd: Add contents of \value section for resample() - man page - * [r1348] tests/tests.write.fwf.Rout.save: Update test output to - remove R CMD check warning - * [r1347] inst/NEWS: Update ChangeLog and NEWS for gdata 2.6.0 - release - * [r1346] DESCRIPTION: Update DESCRIPTION file for gdata 2.6.0 - * [r1345] inst/doc/gregmisc.tex, inst/doc/mapLevels.pdf, + * man/frameApply.Rd: Fix formatting warning in frameApply man page + +2009-07-16 10:55 ggorjan + + * man/write.fwf.Rd: Reverting recent change and clarifying the + meaning. + +2009-07-16 03:23 warnes + + * inst/doc/mapLevels.pdf, inst/doc/unknown.pdf, man/resample.Rd: + Add contents of \value section for resample() man page + +2009-07-16 03:15 warnes + + * tests/tests.write.fwf.Rout.save: Update test output to remove R + CMD check warning + +2009-07-16 03:10 warnes + + * inst/NEWS: Update ChangeLog and NEWS for gdata 2.6.0 release + +2009-07-16 02:56 warnes + + * DESCRIPTION: Update DESCRIPTION file for gdata 2.6.0 + +2009-07-16 02:55 warnes + + * inst/doc/gregmisc.tex, inst/doc/mapLevels.pdf, inst/doc/unknown.pdf, man/ConvertMedUnits.Rd, man/aggregate.table.Rd, man/combine.Rd, man/interleave.Rd, man/matchcols.Rd, man/nobs.Rd, man/rename.vars.Rd, man/reorder.Rd, man/trim.Rd, man/unmatrix.Rd, man/upperTriangle.Rd: Correct Greg's email address - * [r1344] man/write.fwf.Rd: Correct minor typos in write.fwf() man - page - * [r1343] man/resample.Rd: Correct page for resample() - * [r1342] NAMESPACE, R/read.xls.R, inst/perl/xls2tab.pl, - man/read.xls.Rd: Add support for using tab for field separator - during translation from xls format in read.xls -2009-04-19 arnima +2009-07-16 02:52 warnes - * [r1314] R/env.R, R/ll.R: Changed object.size(object) to + * man/write.fwf.Rd: Correct minor typos in write.fwf() man page + +2009-07-16 02:50 warnes + + * man/resample.Rd: Correct page for resample() + +2009-07-16 02:49 warnes + + * NAMESPACE, R/read.xls.R, inst/perl/xls2tab.pl, man/read.xls.Rd: + Add support for using tab for field separator during translation + from xls format in read.xls + +2009-04-19 23:25 arnima + + * R/env.R, R/ll.R: Changed object.size(object) to unclass(object.size(object)). -2008-12-31 ggorjan +2008-12-31 13:30 ggorjan - * [r1312] NAMESPACE, inst/NEWS: Documenting changes and exporting - the functions. - * [r1311] R/object.size.R, man/humanReadable.Rd, - man/object.size.Rd: Enhanced function object.size that returns - the size of multiple objects. There is also a handy print method - that can print size of an object in "human readable" format when + * NAMESPACE, inst/NEWS: Documenting changes and exporting the + functions. + +2008-12-31 13:30 ggorjan + + * R/object.size.R, man/humanReadable.Rd, man/object.size.Rd: + Enhanced function object.size that returns the size of multiple + objects. There is also a handy print method that can print size + of an object in "human readable" format when options(humanReadable=TRUE) or print(object.size(x), humanReadable=TRUE). - * [r1310] R/wideByFactor.R, inst/unitTests/runit.wideByFactor.R, + +2008-12-31 13:29 ggorjan + + * R/wideByFactor.R, inst/unitTests/runit.wideByFactor.R, man/wideByFactor.Rd: New function wideByFactor that reshapes given dataset by a given factor - it creates a "multivariate" data.frame. - * [r1309] R/nPairs.R, inst/unitTests/runit.nPairs.R, man/nPairs.Rd: - New function nPairs that gives the number of variable pairs in a + +2008-12-31 13:28 ggorjan + + * R/nPairs.R, inst/unitTests/runit.nPairs.R, man/nPairs.Rd: New + function nPairs that gives the number of variable pairs in a data.frame or a matrix. - * [r1308] R/getDateTimeParts.R, - inst/unitTests/runit.getDateTimeParts.R, man/getDateTimePart.Rd: - New functions getYear, getMonth, getDay, getHour, getMin, and - getSec for extracting the date/time parts from objects of a - date/time class. - * [r1307] R/bindData.R, inst/unitTests/runit.bindData.R, - man/bindData.Rd: New function bindData that binds two data frames - into a multivariate data frame in a different way than merge. - * [r1306] R/runRUnitTests.R, inst/unitTests/Makefile, + +2008-12-31 13:26 ggorjan + + * R/getDateTimeParts.R, inst/unitTests/runit.getDateTimeParts.R, + man/getDateTimePart.Rd: New functions getYear, getMonth, getDay, + getHour, getMin, and getSec for extracting the date/time parts + from objects of a date/time class. + +2008-12-31 13:25 ggorjan + + * R/bindData.R, inst/unitTests/runit.bindData.R, man/bindData.Rd: + New function bindData that binds two data frames into a + multivariate data frame in a different way than merge. + +2008-12-31 13:24 ggorjan + + * R/runRUnitTests.R, inst/unitTests/Makefile, inst/unitTests/runRUnitTests.R, man/gdata-package.Rd, man/runRUnitTests.Rd, tests/doRUnit.R: New function .runRUnitTestsGdata that enables run of all RUnit tests during the R CMD check as well as directly from within R. -2008-12-20 ggorjan +2008-12-20 22:34 ggorjan - * [r1305] NAMESPACE, R/trimSum.R, inst/NEWS, + * NAMESPACE, R/trimSum.R, inst/NEWS, inst/unitTests/runit.trimSum.R, man/trimSum.Rd: - * [r1304] tests/tests.write.fwf.Rout.save: To remove some output in - the R CMD check -2008-08-05 ggorjan +2008-12-20 22:28 ggorjan - * [r1300] DESCRIPTION, NAMESPACE, R/cbindX.R, R/write.fwf.R, - inst/NEWS, inst/doc/mapLevels.pdf, inst/doc/unknown.pdf, + * tests/tests.write.fwf.Rout.save: To remove some output in the R + CMD check + +2008-08-05 11:47 ggorjan + + * DESCRIPTION, NAMESPACE, R/cbindX.R, R/write.fwf.R, inst/NEWS, + inst/doc/mapLevels.pdf, inst/doc/unknown.pdf, inst/unitTests/runit.cbindX.R, inst/unitTests/runit.write.fwf.R, man/cbindX.Rd, man/write.fwf.Rd, tests/tests.write.fwf.R, tests/tests.write.fwf.Rout.save: - Increased version to 2.5.0 @@ -886,22 +1319,34 @@ the width of the columns. Additional tests and documentation fixes. -2008-06-30 arnima +2008-06-30 22:29 arnima - * [r1299] R/env.R, R/ll.R, man/env.Rd, man/ll.Rd: Simplified - default 'unit' argument from c("KB","MB","bytes") to "KB". + * R/env.R, R/ll.R, man/env.Rd, man/ll.Rd: Simplified default 'unit' + argument from c("KB","MB","bytes") to "KB". -2008-05-13 warnes +2008-05-13 03:16 warnes - * [r1270] inst/NEWS, inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: - Update NEWS file for 2.4.2 - * [r1269] R/read.xls.R: Use path.expand() to give proper full path - to xls file to be translated by read.xls() - * [r1268] R/read.xls.R: Modifed read.xls() failed to return the - converted data... fixed. - * [r1267] inst/perl/Spreadsheet/ParseExcel/Utility.pm: Correct - broken patch for open-office support - * [r1266] DESCRIPTION, R/read.xls.R: For read.xls() and xls2csv(): + * inst/NEWS, inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: Update + NEWS file for 2.4.2 + +2008-05-13 03:09 warnes + + * R/read.xls.R: Use path.expand() to give proper full path to xls + file to be translated by read.xls() + +2008-05-13 02:55 warnes + + * R/read.xls.R: Modifed read.xls() failed to return the converted + data... fixed. + +2008-05-13 02:47 warnes + + * inst/perl/Spreadsheet/ParseExcel/Utility.pm: Correct broken patch + for open-office support + +2008-05-13 02:40 warnes + + * DESCRIPTION, R/read.xls.R: For read.xls() and xls2csv(): - Implement more informative log messages when verbose=TRUE - Quote temporary file name to avoid errors when calling perl to do the work. @@ -911,20 +1356,26 @@ Update version number in DESCRIPTION. -2008-05-12 warnes +2008-05-12 00:00 warnes - * [r1265] inst/perl/Spreadsheet/ParseExcel/Utility.pm: Patch to - correct issue with OpenOffice-created XLS files. Thanks to + * inst/perl/Spreadsheet/ParseExcel/Utility.pm: Patch to correct + issue with OpenOffice-created XLS files. Thanks to Robert Burns for pointing out the patch at http://rt.cpan.org/Public/Bug/Display.html?id=7206 -2008-03-25 warnes +2008-03-25 01:01 warnes - * [r1250] DESCRIPTION, inst/NEWS, inst/doc/mapLevels.pdf, + * DESCRIPTION, inst/NEWS, inst/doc/mapLevels.pdf, inst/doc/unknown.pdf: Update for version 2.4.1 - * [r1249] inst/xls/iris.xls: Example iris.xls file didn't complete - & properly formatted iris data set. Fixed. - * [r1248] inst/perl/IO/AtomicFile.pm, inst/perl/IO/InnerFile.pm, + +2008-03-25 00:57 warnes + + * inst/xls/iris.xls: Example iris.xls file didn't complete & + properly formatted iris data set. Fixed. + +2008-03-25 00:51 warnes + + * inst/perl/IO/AtomicFile.pm, inst/perl/IO/InnerFile.pm, inst/perl/IO/Lines.pm, inst/perl/IO/Scalar.pm, inst/perl/IO/ScalarArray.pm, inst/perl/IO/Stringy.pm, inst/perl/IO/Wrap.pm, inst/perl/IO/WrapTie.pm, @@ -939,250 +1390,351 @@ inst/perl/Spreadsheet/ParseExcel/Utility.pm: Update perl modules to latest versions -2008-03-24 warnes +2008-03-24 23:56 warnes - * [r1247] man/read.xls.Rd: Fix typo in win32 example for read.xls() + * man/read.xls.Rd: Fix typo in win32 example for read.xls() -2008-03-11 warnes +2008-03-11 20:22 warnes - * [r1246] NAMESPACE: Add xls2csv to exported function list + * NAMESPACE: Add xls2csv to exported function list -2008-01-30 warnes +2008-01-30 19:55 warnes - * [r1241] ChangeLog, DESCRIPTION, inst/NEWS: Update DESCRIPTION and - NEWS for release 2.4.0 + * ChangeLog, DESCRIPTION, inst/NEWS: Update DESCRIPTION and NEWS + for release 2.4.0 -2008-01-29 arnima +2008-01-29 11:26 arnima - * [r1240] man/keep.Rd: Added argument 'all'. - * [r1239] R/keep.R: Added argument 'all'. + * man/keep.Rd: Added argument 'all'. -2007-10-22 warnes +2008-01-29 11:09 arnima - * [r1196] DESCRIPTION: Clarify GPL version + * R/keep.R: Added argument 'all'. -2007-09-10 ggorjan +2007-10-22 02:24 warnes - * [r1169] man/upperTriangle.Rd: removed unmatched brace - * [r1168] man/gdata-package.Rd: adding alias + * DESCRIPTION: Clarify GPL version -2007-09-06 ggorjan +2007-09-10 13:39 ggorjan - * [r1162] man/gdata-package.Rd: keyword + * man/upperTriangle.Rd: removed unmatched brace -2007-08-21 ggorjan +2007-09-10 13:02 ggorjan - * [r1154] man/gdata-package.Rd: package help page - * [r1153] NEWS, inst/NEWS: move - * [r1152] NEWS: move + * man/gdata-package.Rd: adding alias -2007-08-20 ggorjan +2007-09-06 14:06 ggorjan - * [r1151] inst/doc/mapLevels.tex: clean - * [r1150] inst/doc/mapLevels.Rnw, ins... [truncated message content] |
From: <wa...@us...> - 2015-04-25 05:54:38
|
Revision: 1957 http://sourceforge.net/p/r-gregmisc/code/1957 Author: warnes Date: 2015-04-25 05:54:28 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Complete work on object.size(), object_sizes methods, and humanReadable. Modified Paths: -------------- trunk/gdata/NAMESPACE trunk/gdata/R/humanReadable.R trunk/gdata/R/object.size.R trunk/gdata/man/humanReadable.Rd trunk/gdata/man/object.size.Rd Added Paths: ----------- trunk/gdata/tests/test.humanReadable.R trunk/gdata/tests/test.humanReadable.Rout.save Modified: trunk/gdata/NAMESPACE =================================================================== --- trunk/gdata/NAMESPACE 2015-04-25 02:52:53 UTC (rev 1956) +++ trunk/gdata/NAMESPACE 2015-04-25 05:54:28 UTC (rev 1957) @@ -129,8 +129,11 @@ S3method(nobs, lm) # now provided by stats package ## Object size stuff -S3method(print, object_sizes) -S3method(c, object_sizes) +S3method(c, object_sizes) +S3method(as, object_sizes) +S3method(format, object_sizes) +S3method(is, object_sizes) +S3method(print, object_sizes) ## unknown stuff S3method(isUnknown, default) Modified: trunk/gdata/R/humanReadable.R =================================================================== --- trunk/gdata/R/humanReadable.R 2015-04-25 02:52:53 UTC (rev 1956) +++ trunk/gdata/R/humanReadable.R 2015-04-25 05:54:28 UTC (rev 1957) @@ -1,61 +1,89 @@ -humanReadable <- function(x, standard=c("SI", "IEC"), units, digits=1, width=3, sep=" ") +humanReadable <- function(x, + units="auto", + standard=c("IEC", "SI", "Unix"), + digits=1, + width=NULL, + sep=" ", + justify = c("right", "left"), + ... + ) { ## --- Setup --- - suffix.decimal <- c("B", "kB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB") - suffix.binary <- c("B", "KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB") + suffix.SI <- c("B", "kB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB") + suffix.IEC <- c("B", "KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB") + suffix.Unix <- c("B" , "K", "M", "G", "T", "P", "E", "Z", "Y") standard <- match.arg(standard) - + if(length(justify)==1) justfy <- c(justify, justify) + ## --- Functions --- .applyHuman <- function(x, base, suffix, digits, width, sep) { ## Which suffix should we use? n <- length(suffix) - for(i in 1:n) { - if(x >= base) { - if(i < n) x <- x / base - } else { - break - } - } + i <- pmax(pmin(floor(log(x, base)), n-1),0) + if(!is.finite(i)) i <- 0 + x <- x / base^i ## Formatting - if(is.null(width)) { ## the same formatting for all - x <- format(round(x=x, digits=digits), nsmall=digits) - } else { ## similar to ls, du, and df - lenX <- nchar(x) - if(lenX > width) { - digitsMy <- width - (lenX - (lenX - (nchar(round(x)) + 1))) - digits <- ifelse(digitsMy > digits, digits, digitsMy) - } - if(i == 1) digits <- 0 - x <- round(x, digits=digits) - } - paste(x, suffix[i], sep=sep) + if(is.null(width)) + ## the same formatting for all + x <- format(round(x=x, digits=digits), nsmall=digits) + else + { + ## similar to ls, du, and df + lenX <- nchar(x) + if(lenX > width) { + digits <- pmax( width - nchar(round(x)) - 1, 0) + } + if(i == 0) digits <- 0 + x <- round(x, digits=digits) + } + c(x, suffix[i+1]) } ## -- Work - + if(any(x < 0)) stop("'x' must be positive") - if(standard == "SI") { - suffix <- suffix.decimal - base <- 10^3 - } else { - suffix <- suffix.binary - base <- 2^10 - } + if(standard == "SI") + { + suffix <- suffix.SI + base <- 10^3 + } + else if (standard=="IEC") + { + suffix <- suffix.IEC + base <- 2^10 + } + else # (standard=="Unix) + { + suffix <- suffix.Unix + base <- 2^10 + } - if(!missing(units)) + if(!missing(units) && units=="bytes") { - units <- match.arg( units, suffix ) + retval <- rbind(x, "bytes") + } + else if(!missing(units) && units!="auto") + { + units <- suffix[match( toupper(units), toupper(suffix) )] power <- match(units, suffix ) -1 X <- x/(base^power) - X <- format.default(round(x=X, digits=digits), nsmall=digits) - X <- paste(X, units) - X + X <- format.default(x=X, digits=digits, nsmall=digits) + retval <- rbind(X, rep(units, length(X))) } else - sapply(X=x, FUN=".applyHuman", base=base, suffix=suffix, digits=digits, - width=width, sep=sep) + retval <- sapply(X=x, FUN=".applyHuman", base=base, suffix=suffix, + digits=digits, width=width, sep=sep) + + if(all(justify == "none")) + paste(trim(retval[1,]), trim(retval[2,]), sep=sep) + else + paste(format(trim(retval[1,]), justify=justify[1]), + format(trim(retval[2,]), justify=justify[2]), + sep=sep) + } + Modified: trunk/gdata/R/object.size.R =================================================================== --- trunk/gdata/R/object.size.R 2015-04-25 02:52:53 UTC (rev 1956) +++ trunk/gdata/R/object.size.R 2015-04-25 05:54:28 UTC (rev 1957) @@ -1,38 +1,79 @@ -### object.size.R ###------------------------------------------------------------------------ ### What: Print object size in human readable format - code -### $Id$ -### Time-stamp: <2008-12-30 08:05:43 ggorjan> ###------------------------------------------------------------------------ -object.size <- function(...) +object.size <- function(...) { structure(sapply(list(...), utils::object.size), class=c("object_sizes", "numeric")) } -print.object_sizes <- function(x, quote=FALSE, units, - humanReadable, ...) -{ - xOrig <- x - if(missing(humanReadable)) { - opt <- getOption("humanReadable") - humanReadable <- ifelse(!is.null(opt), opt, FALSE) - } - if(humanReadable) { - print(humanReadable(x), quote=quote, ...) - } else { - class(x) <- "numeric" - NextMethod() - } - invisible(xOrig) +print.object_sizes <- function(x, + quote=FALSE, + humanReadable=getOption("humanReadable"), + standard="IEC", + units, + digits=1, + width=NULL, + sep=" ", + ...) +{ + print(format(x, + humanReadable=humanReadable, + standard=standard, + units=units, + digits=digits, + width=width, + sep=sep), + quote=quote, + ...) + + + invisible(x) } +format.object_sizes <- function(x, + humanReadable=getOption("humanReadable"), + standard="IEC", + units, + digits=1, + width=NULL, + sep=" ", + ...) +{ + if( !missing(units) ) + { + if (units=="bytes") + paste(x, "bytes") + else + humanReadable(x, + standard=standard, + units=units, + digits=digits, + width=width, + sep=sep + ) + } + else if( is.null(humanReadable) || humanReadable==FALSE ) + paste(x, "bytes") + else + humanReadable(x, + standard=standard, + units=units, + digits=digits, + width=width, + sep=sep) + +} + + + is.object_sizes <- function(x) inherits(x, what="object_sizes") - + as.object_sizes <- function(x) { - if(!is.numeric(x)) stop("'x' must be numeric/integer") + if(!is.numeric(x) || any(x<0)) stop("'x' must be a positive numeric vector") + class(x) <- c("object_sizes", "numeric") x } @@ -44,66 +85,5 @@ x } -humanReadable <- function(x, standard="SI", units, digits=1, width=3, sep=" ") -{ - ## --- Setup --- - - suffix.decimal <- c("B", "kB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB") - suffix.binary <- c("B", "KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB") - - ## --- Functions --- - - .applyHuman <- function(x, base, suffix, digits, width, sep) - { - ## Which suffix should we use? - n <- length(suffix) - for(i in 1:n) { - if(x >= base) { - if(i < n) x <- x / base - } else { - break - } - } - ## Formatting - if(is.null(width)) { ## the same formatting for all - x <- format(round(x=x, digits=digits), nsmall=digits) - } else { ## similar to ls, du, and df - lenX <- nchar(x) - if(lenX > width) { - digitsMy <- width - (lenX - (lenX - (nchar(round(x)) + 1))) - digits <- ifelse(digitsMy > digits, digits, digitsMy) - } - if(i == 1) digits <- 0 - x <- round(x, digits=digits) - } - paste(x, suffix[i], sep=sep) - } - - ## -- Work - - if(any(x < 0)) stop("'x' must be positive") - if(standard == "SI") { - suffix <- suffix.decimal - base <- 10^3 - } else { - suffix <- suffix.binary - base <- 2^10 - } - - if(!missing(units)) - { - units <- match.arg( units, suffix ) - power <- which( units %in% suffix ) -1 - X <- x/(base^power) - X <- format.default(round(x=x, digits=digits), nsmall=digits) - X <- paste(X, units) - X - } - else - sapply(X=x, FUN=".applyHuman", base=base, suffix=suffix, digits=digits, - width=width, sep=sep) -} - - ###------------------------------------------------------------------------ ### object.size.R ends here Modified: trunk/gdata/man/humanReadable.Rd =================================================================== --- trunk/gdata/man/humanReadable.Rd 2015-04-25 02:52:53 UTC (rev 1956) +++ trunk/gdata/man/humanReadable.Rd 2015-04-25 05:54:28 UTC (rev 1957) @@ -1,43 +1,44 @@ -% humanReadable.Rd -%-------------------------------------------------------------------------- -% What: Print byte size in human readable format man page -% $Id$ -% Time-stamp: <2008-12-30 13:26:35 ggorjan> -%-------------------------------------------------------------------------- - \name{humanReadable} \alias{humanReadable} -\title{Print byte size in human readable format} +\title{Print Byte Size in Human Readable Format} \description{ -\code{humanReadable} converts byte size in human readable format such as +\code{humanReadable} converts integer byte sizes to a human readable units such as kB, MB, GB, etc. } \usage{ -humanReadable(x, standard=c("SI","IEC"), units, digits=1, width=3, sep=" ") +humanReadable(x, units="auto", standard=c("IEC", "SI", "Unix"), + digits=1, width=NULL, sep=" ", justify=c("right", "left"), + \dots) } \arguments{ \item{x}{integer, byte size} - \item{standard}{character, either "SI" for powers of 1000 or "IEC" for - powers of 1024, see details} - \item{units}{character, unit to use for all values (optional)} + \item{standard}{character, "IEC" for powers of 1024 ('MiB'), "SI" for + powers of 1000 ('MB'), or "Unix" for powers of 1024 ('M'). See + details.} + \item{units}{character, unit to use for all values (optional), one of + "auto", "bytes", or an appropriate unit corresponding to + \code{standard}.} \item{digits}{integer, number of digits after decimal point} \item{width}{integer, width of number string} \item{sep}{character, separator between number and unit} + \item{justify}{two-element vector specifiy the alignment for the number + and unit components of the size. Each element should be one of + "none", "left", "right", or "center"} } \details{ -Basic unit used to store information in computers is a bit. Bits are +The basic unit used to store information in computers is a bit. Bits are represented as zeroes and ones - binary number system. Although, the binary number system is not the same as the decimal number system, decimal prefixes -for binary multiples such as kilo and mega are often used. In the decimal system +for binary multiples such as kilo and mega are often used. In the decimal system kilo represent 1000, which is close to \eqn{1024 = 2^{10}} in the binary system. This sometimes causes problems as it is not clear which powers (2 or 10) are used in a notation like 1 kB. To overcome this problem International Electrotechnical @@ -65,14 +66,30 @@ } where Zi and Yi are GNU extensions to IEC. To get the output in the decimal -system (powers of 1000) use \code{standard="SI"}. Otherwise IEC standard -(powers of 1024) is used. +system (powers of 1000) use \code{standard="SI"}. To obtain IEC standard +(powers of 1024) use \code{standard="IEC"}. +In addition, single-character units are provided that follow (and +extend) the Unix pattern (use \code{standard="Unix"}): + +\tabular{lrcll}{ +Name \tab System \tab Symbol \tab Size \tab Conversion \cr +byte \tab binary \tab B \tab \eqn{2^3} \tab 8 bits \cr +kibibyte \tab binary \tab K \tab \eqn{2^{10}} \tab 1024 bytes \cr +mebibyte \tab binary \tab M \tab \eqn{(2^{10})^2} \tab 1024 kibibytes\cr +gibibyte \tab binary \tab G \tab \eqn{(2^{10})^3} \tab 1024 mebibytes\cr +tebibyte \tab binary \tab T \tab \eqn{(2^{10})^4} \tab 1024 gibibytes\cr +pebibyte \tab binary \tab P \tab \eqn{(2^{10})^5} \tab 1024 tebibytes\cr +exbibyte \tab binary \tab E \tab \eqn{(2^{10})^6} \tab 1024 pebibytes\cr +zebibyte \tab binary \tab Z \tab \eqn{(2^{10})^7} \tab 1024 exbibytes\cr +yottabyte \tab binary \tab Y \tab \eqn{(2^{10})^8} \tab 1024 zebibytes\cr +} + For printout both \code{digits} and \code{width} can be specified. If \code{width} is \code{NULL}, all values have given number of digits. If \code{width} is not \code{NULL}, output is rounded to a given width and -formated similar to human readable format of \code{ls}, \code{df} or -\code{du} shell commands. +formated similar to human readable format of the Unix \code{ls}, +\code{df} or \code{du} shell commands. } @@ -95,51 +112,40 @@ } -\author{Ales Korosec and Gregor Gorjanc} +\author{Ales Korosec, Gregor Gorjanc, and Gregory R. Warnes + \email{gr...@wa...}} + \seealso{ - \code{\link{object.size}}, \code{\link[gdata]{ll}} + \code{\link{object.size}} in package 'gdata', + \code{\link[utils]{object.size}} in package 'utils', + \code{\link[gdata]{ll}} } \examples{ # Simple example: maximum addressible size of 32 bit pointer +humanReadable(2^32-1) +humanReadable(2^32-1, standard="IEC") humanReadable(2^32-1, standard="SI") -humanReadable(2^32-1, standard="IEC") +humanReadable(2^32-1, standard="Unix") -humanReadable(2^32-1, standard="SI", unit="MB") -humanReadable(2^32-1, standard="IEC", unit="MiB") +humanReadable(2^32-1, unit="MiB") +humanReadable(2^32-1, standard="IEC", unit="MiB") +humanReadable(2^32-1, standard="SI", unit="MB") +humanReadable(2^32-1, standard="Unix", unit="M") +# Vector of sizes +matrix(humanReadable(c(60810, 124141, 124, 13412513), width=4)) +matrix(humanReadable(c(60810, 124141, 124, 13412513), width=4, unit="KiB")) -baseSI <- 10 -powerSI <- seq(from=3, to=27, by=3) -SI0 <- (baseSI)^powerSI -k <- length(SI0) - 1 -SI1 <- SI0 - SI0 / c(2, runif(n=k, min=1.01, max=5.99)) -SI2 <- SI0 + SI0 / c(2, runif(n=k, min=1.01, max=5.99)) +# Specify digits rather than width +matrix(humanReadable(c(60810, 124141, 124, 13412513), width=NULL, digits=2)) -baseIEC <- 2 -powerIEC <- seq(from=10, to=90, by=10) -IEC0 <- (baseIEC)^powerIEC -IEC1 <- IEC0 - IEC0 / c(2, runif(n=k, min=1.01, max=5.99)) -IEC2 <- IEC0 + IEC0 / c(2, runif(n=k, min=1.01, max=5.99)) +# Change the justification +matrix(humanReadable(c(60810, 124141, 124, 13412513), width=NULL, + justify=c("right", "right") )) -# Auto units -cbind(humanReadable(x=SI1, width=NULL, digits=3), - humanReadable(x=SI0, width=NULL, digits=2), - humanReadable(x=SI2, width=NULL, digits=1), - humanReadable(x=IEC1, standard="IEC", width=7, digits=3), - humanReadable(x=IEC0, standard="IEC", width=7, digits=2), - humanReadable(x=IEC2, standard="IEC", width=7, digits=1)) - -# Single unit -cbind(humanReadable(x=SI1, units="GB", width=NULL, digits=3), - humanReadable(x=SI0, units="GB", width=NULL, digits=2), - humanReadable(x=SI2, units="GB", width=NULL, digits=1), - humanReadable(x=IEC1, units="GiB", standard="IEC", width=7, digits=3), - humanReadable(x=IEC0, units="GiB", standard="IEC", width=7, digits=2), - humanReadable(x=IEC2, units="GiB", standard="IEC", width=7, digits=1)) - } \keyword{misc} Modified: trunk/gdata/man/object.size.Rd =================================================================== --- trunk/gdata/man/object.size.Rd 2015-04-25 02:52:53 UTC (rev 1956) +++ trunk/gdata/man/object.size.Rd 2015-04-25 05:54:28 UTC (rev 1957) @@ -1,70 +1,95 @@ -% File src/library/utils/man/object.size.Rd +% Come material taken from src/library/utils/man/object.size.Rd % Part of the R package, http://www.R-project.org % Copyright 1995-2007 R Core Development Team % Distributed under GPL 2 or later \name{object.size} \alias{object.size} -\alias{print.object_sizes} \alias{c.object_sizes} \alias{as.object_sizes} \alias{is.object_sizes} +\alias{format.object_sizes} +\alias{print.object_sizes} -\title{Report the Space Allocated for an Object} +\title{Report the Space Allocated for Objects} \description{ - Provides an estimate of the memory that is being used to store an \R object. + Provides an estimate of the memory that is being used to store \R objects. } \usage{ object.size(\dots) -\method{print}{object_sizes}(x, quote=FALSE, humanReadable, \dots) +\method{is}{object_sizes}(x) + +\method{as}{object_sizes}(x) + +\method{c}{object_sizes}(x) + +\method{format}{object_sizes}(x, humanReadable=getOption("humanReadable"), standard="IEC", units, + digits=1, width=NULL, sep=" ", \dots) + +\method{print}{object_sizes}x, quote=FALSE, humanReadable=getOption("humanReadable"), + standard="IEC", units, digits=1, width=NULL, sep=" ", \dots) + } \arguments{ - \item{\dots}{\code{object.size}: \R objects; \code{print}; arguments - to be passed to or from other methods.} + \item{\dots}{\code{object.size}: \R objects; + \code{print}: arguments to be passed to other methods.} \item{x}{output from \code{object.size}} \item{quote}{logical, indicating whether or not the result should be printed with surrounding quotes.} \item{humanReadable}{logical, use the \dQuote{human readable} format.} + \item{standard,units,digits,width,sep,justify}{arguments passed to + \code{\link{humanReadable}}. See the \code{\link{humanReadable}} + man page for details. + } } \details{ - This is a modified copy from the utils package in R as fo 2008-12-15. + \emph{This is a modified copy of the man page for utils::object.size in R + 2.2.1.} - Exactly which parts of the memory allocation should be attributed to - which object is not clear-cut. This function merely provides a rough - indication: it should be reasonably accurate for atomic vectors, but - does not detect if elements of a list are shared, for example. - (Sharing amongst elements of a character vector is taken into account, - but not that between character vectors in a single object.) - - The calculation is of the size of the object, and excludes the space - needed to store its name in the symbol table. + Exactly which parts of the memory allocation should be attributed + to which object is not clear-cut. This function merely provides a + rough indication: it should be reasonably accurate for atomic + vectors, but does not detect if elements of a list are shared, for + example. (Sharing amongst elements of a character vector is taken + into account, but not that between character vectors in a single + object.) - Associated space (e.g. the environment of a function and what the - pointer in a \code{EXTPTRSXP} points to) is not included in the + The calculation is of the size of the object, and excludes the + space needed to store its name in the symbol table. + + Associated space (e.g., the environment of a function and what the + pointer in a ‘EXTPTRSXP’ points to) is not included in the calculation. - Object sizes are larger on 64-bit platforms than 32-bit ones, but will - very likely be the same on different platforms with the same word - length and pointer size. + Object sizes are larger on 64-bit builds than 32-bit ones, but + will very likely be the same on different platforms with the same + word length and pointer size. % Modificitaion start - Class of returned object is \code{c("byte", "numeric")} with + \emph{Changes} + + Class of returned object is \code{c("object_sizes", "numeric")} with appropriate \code{print} and \code{c} methods. By default \code{object.size} outputs size in bytes, but human readable format similar to \code{ls}, \code{df} or \code{du} shell - commands can be invoked with \code{options(humanReadable=TRUE)}. + commands can be displayed by calling \code{humanReadable} directly, + calling \code{print} with the argument \code{humanReadable=TRUE}, or + by setting \code{options(humanReadable=TRUE)}. + % Modificitaion end } \value{ - An object of class \code{"object.size"} with a length-one double value, - an estimate of the memory allocation attributable to the object in bytes. + A numeric vector class \code{c("object_sizes", "numeric")} containing + estimated memory allocation attributable to the objects in bytes. } \seealso{ - \code{\link{Memory-limits}} for the design limitations on object size. + \code{\link[utils]{object.size}} in package 'utils' for the standard + version of this function, + \code{\link{Memory-limits}} for the design limitations on object size, \code{\link{humanReadable}} for human readable format. } @@ -72,14 +97,35 @@ object.size(letters) object.size(ls) ## find the 10 largest objects in the base package -z <- sapply(ls("package:base"), function(x) - object.size(get(x, envir = baseenv()))) -(tmp <- as.matrix(rev(sort(z))[1:10])) +allObj <- sapply(ls("package:base"), + function(x) + object.size(get(x, envir = baseenv())) + ) +( bigObj <- as.object_sizes(rev(sort(allObj))[1:10] ) ) +print(bigObj, humanReadable=TRUE) + + as.object_sizes(14567567) + +\dontshow{ + optionsOrig <- options("humanReadable") +} + options(humanReadable=TRUE) -(z <- object.size(letters, c(letters, letters), rep(letters, 100), rep(letters, 10000))) +( + z <- object.size(letters, + c(letters, letters), + rep(letters, 100), + rep(letters, 10000) + ) +) is.object_sizes(z) as.object_sizes(14567567) + +\dontshow{ + options(optionsOrig) } + +} \keyword{utilities} Added: trunk/gdata/tests/test.humanReadable.R =================================================================== --- trunk/gdata/tests/test.humanReadable.R (rev 0) +++ trunk/gdata/tests/test.humanReadable.R 2015-04-25 05:54:28 UTC (rev 1957) @@ -0,0 +1,91 @@ +library(gdata) + +options(humanReadable=FALSE) + +baseSI <- 10 +powerSI <- seq(from=0, to=27, by=3) +SI0 <- (baseSI)^powerSI +k <- length(SI0) - 1 +SI1 <- SI0 - SI0 / c(2, runif(n=k, min=1.01, max=5.99)) +SI2 <- SI0 + SI0 / c(2, runif(n=k, min=1.01, max=5.99)) + +baseIEC <- 2 +powerIEC <- seq(from=0, to=90, by=10) +IEC0 <- (baseIEC)^powerIEC +IEC1 <- IEC0 - IEC0 / c(2, runif(n=k, min=1.01, max=5.99)) +IEC2 <- IEC0 + IEC0 / c(2, runif(n=k, min=1.01, max=5.99)) + +# Auto units, specify width +cbind(humanReadable(x=SI2, standard="SI", width=7), + humanReadable(x=SI2, standard="SI", width=5), + humanReadable(x=SI2, standard="SI", width=3), + humanReadable(x=IEC2, standard="IEC", width=7), + humanReadable(x=IEC2, standard="IEC", width=5), + humanReadable(x=IEC2, standard="IEC", width=3), + humanReadable(x=IEC2, standard="Unix", width=7), + humanReadable(x=IEC2, standard="Unix", width=5), + humanReadable(x=IEC2, standard="Unix", width=3)) + +# Auto units, specify digits +cbind(humanReadable(x=SI2, standard="SI", width=NULL, digits=7), + humanReadable(x=SI2, standard="SI", width=NULL, digits=3), + humanReadable(x=SI2, standard="SI", width=NULL, digits=2), + humanReadable(x=SI2, standard="SI", width=NULL, digits=1), + humanReadable(x=IEC2, standard="IEC", width=NULL, digits=7), + humanReadable(x=IEC2, standard="IEC", width=NULL, digits=3), + humanReadable(x=IEC2, standard="IEC", width=NULL, digits=2), + humanReadable(x=IEC2, standard="IEC", width=NULL, digits=1), + humanReadable(x=IEC2, standard="Unix", width=NULL, digits=7), + humanReadable(x=IEC2, standard="Unix", width=NULL, digits=3), + humanReadable(x=IEC2, standard="Unix", width=NULL, digits=2), + humanReadable(x=IEC2, standard="Unix", width=NULL, digits=1)) + +# Single unit, specify width +cbind(humanReadable(x=SI1, units="GB", standard="SI", width=7), + humanReadable(x=SI1, units="GB", standard="SI", width=5), + humanReadable(x=SI1, units="GB", standard="SI", width=3), + humanReadable(x=IEC1, units="GiB", standard="IEC", width=7), + humanReadable(x=IEC1, units="GiB", standard="IEC", width=5), + humanReadable(x=IEC1, units="GiB", standard="IEC", width=3), + humanReadable(x=IEC1, units="G", standard="Unix", width=7), + humanReadable(x=IEC1, units="G", standard="Unix", width=5), + humanReadable(x=IEC1, units="G", standard="Unix", width=3) + ) + +# Single unit, specify digits +cbind(humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=7), + humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=3), + humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=2), + humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=1), + humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=7), + humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=3), + humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=2), + humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=1), + humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=7), + humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=3), + humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=2), + humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=1) + ) + + +stopifnot( is.object_sizes(as.object_sizes( 2^(1:30) ) ) ) +stopifnot( format(as.object_sizes(124)) == "124 bytes") +stopifnot( format(as.object_sizes(124e8), units="auto") == "11.5 GiB") +stopifnot( format(as.object_sizes(124e8), humanReadable=TRUE) == "11.5 GiB") +stopifnot( format(as.object_sizes(124e8), units="bytes") == "1.24e+10 bytes") + +tools::assertError( as.object_sizes(-1) ) +tools::assertError( as.object_sizes('a') ) +tools::assertError( as.object_sizes(list()) ) +tools::assertError( as.object_sizes(NULL) ) +tools::assertError( as.object_sizes(0+1i) ) + +stopifnot( format(as.object_sizes(1e40) ) == "1e+40 bytes" ) +stopifnot( format(as.object_sizes(1e40), units="auto" ) == "8.271806e+15 YiB") +stopifnot( format(as.object_sizes(1e40), units="bytes") == "1e+40 bytes" ) +stopifnot( format(as.object_sizes(1e40), humanReadable=TRUE) == "8.271806e+15 YiB") +stopifnot( format(as.object_sizes(1e40), humanReadable=FALSE) == "1e+40 bytes") + +options(humanReadable=TRUE) +stopifnot( format(as.object_sizes(1e40) ) == "8.271806e+15 YiB") +options(humanReadable=FALSE) Added: trunk/gdata/tests/test.humanReadable.Rout.save =================================================================== --- trunk/gdata/tests/test.humanReadable.Rout.save (rev 0) +++ trunk/gdata/tests/test.humanReadable.Rout.save 2015-04-25 05:54:28 UTC (rev 1957) @@ -0,0 +1,243 @@ + +R version 3.1.2 (2014-10-31) -- "Pumpkin Helmet" +Copyright (C) 2014 The R Foundation for Statistical Computing +Platform: x86_64-apple-darwin13.4.0 (64-bit) + +R is free software and comes with ABSOLUTELY NO WARRANTY. +You are welcome to redistribute it under certain conditions. +Type 'license()' or 'licence()' for distribution details. + + Natural language support but running in an English locale + +R is a collaborative project with many contributors. +Type 'contributors()' for more information and +'citation()' on how to cite R or R packages in publications. + +Type 'demo()' for some demos, 'help()' for on-line help, or +'help.start()' for an HTML browser interface to help. +Type 'q()' to quit R. + +> library(gdata) +gdata: read.xls support for 'XLS' (Excel 97-2004) files ENABLED. + +gdata: Unable to load perl libaries needed by read.xls() +gdata: to support 'XLSX' (Excel 2007+) files. + +gdata: Run the function 'installXLSXsupport()' +gdata: to automatically download and install the perl +gdata: libaries needed to support Excel XLS and XLSX formats. + +Attaching package: ‘gdata’ + +The following object is masked from ‘package:stats’: + + nobs + +The following object is masked from ‘package:utils’: + + object.size + +> +> options(humanReadable=FALSE) +> +> baseSI <- 10 +> powerSI <- seq(from=0, to=27, by=3) +> SI0 <- (baseSI)^powerSI +> k <- length(SI0) - 1 +> SI1 <- SI0 - SI0 / c(2, runif(n=k, min=1.01, max=5.99)) +> SI2 <- SI0 + SI0 / c(2, runif(n=k, min=1.01, max=5.99)) +> +> baseIEC <- 2 +> powerIEC <- seq(from=0, to=90, by=10) +> IEC0 <- (baseIEC)^powerIEC +> IEC1 <- IEC0 - IEC0 / c(2, runif(n=k, min=1.01, max=5.99)) +> IEC2 <- IEC0 + IEC0 / c(2, runif(n=k, min=1.01, max=5.99)) +> +> # Auto units, specify width +> cbind(humanReadable(x=SI2, standard="SI", width=7), ++ humanReadable(x=SI2, standard="SI", width=5), ++ humanReadable(x=SI2, standard="SI", width=3), ++ humanReadable(x=IEC2, standard="IEC", width=7), ++ humanReadable(x=IEC2, standard="IEC", width=5), ++ humanReadable(x=IEC2, standard="IEC", width=3), ++ humanReadable(x=IEC2, standard="Unix", width=7), ++ humanReadable(x=IEC2, standard="Unix", width=5), ++ humanReadable(x=IEC2, standard="Unix", width=3)) + [,1] [,2] [,3] [,4] [,5] [,6] + [1,] " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " " 2 B " + [2,] "1.26838 kB" "1.268 kB" " 1.3 kB" "1.25729 KiB" "1.257 KiB" " 1.3 KiB" + [3,] " 1.2285 MB" "1.228 MB" " 1.2 MB" "1.83751 MiB" "1.838 MiB" " 1.8 MiB" + [4,] "1.24401 GB" "1.244 GB" " 1.2 GB" "1.26666 GiB" "1.267 GiB" " 1.3 GiB" + [5,] "1.47565 TB" "1.476 TB" " 1.5 TB" " 1.4234 TiB" "1.423 TiB" " 1.4 TiB" + [6,] "1.36687 PB" "1.367 PB" " 1.4 PB" "1.32499 PiB" "1.325 PiB" " 1.3 PiB" + [7,] "1.21324 EB" "1.213 EB" " 1.2 EB" "1.54391 EiB" "1.544 EiB" " 1.5 EiB" + [8,] "1.37186 ZB" "1.372 ZB" " 1.4 ZB" " 1.233 ZiB" "1.233 ZiB" " 1.2 ZiB" + [9,] "1.19468 YB" "1.195 YB" " 1.2 YB" "1.21258 YiB" "1.213 YiB" " 1.2 YiB" +[10,] "1201.13 YB" " 1201 YB" "1201 YB" "1489.01 YiB" " 1489 YiB" "1489 YiB" + [,7] [,8] [,9] + [1,] " 2 B" " 2 B" " 2 B" + [2,] "1.25729 K" "1.257 K" " 1.3 K" + [3,] "1.83751 M" "1.838 M" " 1.8 M" + [4,] "1.26666 G" "1.267 G" " 1.3 G" + [5,] " 1.4234 T" "1.423 T" " 1.4 T" + [6,] "1.32499 P" "1.325 P" " 1.3 P" + [7,] "1.54391 E" "1.544 E" " 1.5 E" + [8,] " 1.233 Z" "1.233 Z" " 1.2 Z" + [9,] "1.21258 Y" "1.213 Y" " 1.2 Y" +[10,] "1489.01 Y" " 1489 Y" "1489 Y" +> +> # Auto units, specify digits +> cbind(humanReadable(x=SI2, standard="SI", width=NULL, digits=7), ++ humanReadable(x=SI2, standard="SI", width=NULL, digits=3), ++ humanReadable(x=SI2, standard="SI", width=NULL, digits=2), ++ humanReadable(x=SI2, standard="SI", width=NULL, digits=1), ++ humanReadable(x=IEC2, standard="IEC", width=NULL, digits=7), ++ humanReadable(x=IEC2, standard="IEC", width=NULL, digits=3), ++ humanReadable(x=IEC2, standard="IEC", width=NULL, digits=2), ++ humanReadable(x=IEC2, standard="IEC", width=NULL, digits=1), ++ humanReadable(x=IEC2, standard="Unix", width=NULL, digits=7), ++ humanReadable(x=IEC2, standard="Unix", width=NULL, digits=3), ++ humanReadable(x=IEC2, standard="Unix", width=NULL, digits=2), ++ humanReadable(x=IEC2, standard="Unix", width=NULL, digits=1)) + [,1] [,2] [,3] [,4] + [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " + [2,] " 1.2683780 kB" " 1.268 kB" " 1.27 kB" " 1.3 kB" + [3,] " 1.2284981 MB" " 1.228 MB" " 1.23 MB" " 1.2 MB" + [4,] " 1.2440094 GB" " 1.244 GB" " 1.24 GB" " 1.2 GB" + [5,] " 1.4756474 TB" " 1.476 TB" " 1.48 TB" " 1.5 TB" + [6,] " 1.3668711 PB" " 1.367 PB" " 1.37 PB" " 1.4 PB" + [7,] " 1.2132416 EB" " 1.213 EB" " 1.21 EB" " 1.2 EB" + [8,] " 1.3718619 ZB" " 1.372 ZB" " 1.37 ZB" " 1.4 ZB" + [9,] " 1.1946775 YB" " 1.195 YB" " 1.19 YB" " 1.2 YB" +[10,] "1201.1346574 YB" "1201.135 YB" "1201.13 YB" "1201.1 YB" + [,5] [,6] [,7] [,8] + [1,] " 1.5000000 B " " 1.500 B " " 1.50 B " " 1.5 B " + [2,] " 1.2572859 KiB" " 1.257 KiB" " 1.26 KiB" " 1.3 KiB" + [3,] " 1.8375086 MiB" " 1.838 MiB" " 1.84 MiB" " 1.8 MiB" + [4,] " 1.2666626 GiB" " 1.267 GiB" " 1.27 GiB" " 1.3 GiB" + [5,] " 1.4234036 TiB" " 1.423 TiB" " 1.42 TiB" " 1.4 TiB" + [6,] " 1.3249855 PiB" " 1.325 PiB" " 1.32 PiB" " 1.3 PiB" + [7,] " 1.5439083 EiB" " 1.544 EiB" " 1.54 EiB" " 1.5 EiB" + [8,] " 1.2329980 ZiB" " 1.233 ZiB" " 1.23 ZiB" " 1.2 ZiB" + [9,] " 1.2125791 YiB" " 1.213 YiB" " 1.21 YiB" " 1.2 YiB" +[10,] "1489.0123170 YiB" "1489.012 YiB" "1489.01 YiB" "1489.0 YiB" + [,9] [,10] [,11] [,12] + [1,] " 1.5000000 B" " 1.500 B" " 1.50 B" " 1.5 B" + [2,] " 1.2572859 K" " 1.257 K" " 1.26 K" " 1.3 K" + [3,] " 1.8375086 M" " 1.838 M" " 1.84 M" " 1.8 M" + [4,] " 1.2666626 G" " 1.267 G" " 1.27 G" " 1.3 G" + [5,] " 1.4234036 T" " 1.423 T" " 1.42 T" " 1.4 T" + [6,] " 1.3249855 P" " 1.325 P" " 1.32 P" " 1.3 P" + [7,] " 1.5439083 E" " 1.544 E" " 1.54 E" " 1.5 E" + [8,] " 1.2329980 Z" " 1.233 Z" " 1.23 Z" " 1.2 Z" + [9,] " 1.2125791 Y" " 1.213 Y" " 1.21 Y" " 1.2 Y" +[10,] "1489.0123170 Y" "1489.012 Y" "1489.01 Y" "1489.0 Y" +> +> # Single unit, specify width +> cbind(humanReadable(x=SI1, units="GB", standard="SI", width=7), ++ humanReadable(x=SI1, units="GB", standard="SI", width=5), ++ humanReadable(x=SI1, units="GB", standard="SI", width=3), ++ humanReadable(x=IEC1, units="GiB", standard="IEC", width=7), ++ humanReadable(x=IEC1, units="GiB", standard="IEC", width=5), ++ humanReadable(x=IEC1, units="GiB", standard="IEC", width=3), ++ humanReadable(x=IEC1, units="G", standard="Unix", width=7), ++ humanReadable(x=IEC1, units="G", standard="Unix", width=5), ++ humanReadable(x=IEC1, units="G", standard="Unix", width=3) ++ ) + [,1] [,2] [,3] [,4] [,5] [,6] + [1,] "5e-10 GB" "5e-10 GB" "5e-10 GB" "5e-10 GiB" "5e-10 GiB" "5e-10 GiB" + [2,] "6e-07 GB" "6e-07 GB" "6e-07 GB" "6e-07 GiB" "6e-07 GiB" "6e-07 GiB" + [3,] "7e-04 GB" "7e-04 GB" "7e-04 GB" "7e-04 GiB" "7e-04 GiB" "7e-04 GiB" + [4,] "8e-01 GB" "8e-01 GB" "8e-01 GB" "8e-01 GiB" "8e-01 GiB" "8e-01 GiB" + [5,] "7e+02 GB" "7e+02 GB" "7e+02 GB" "3e+02 GiB" "3e+02 GiB" "3e+02 GiB" + [6,] "8e+05 GB" "8e+05 GB" "8e+05 GB" "7e+05 GiB" "7e+05 GiB" "7e+05 GiB" + [7,] "8e+08 GB" "8e+08 GB" "8e+08 GB" "8e+08 GiB" "8e+08 GiB" "8e+08 GiB" + [8,] "8e+11 GB" "8e+11 GB" "8e+11 GB" "5e+11 GiB" "5e+11 GiB" "5e+11 GiB" + [9,] "7e+14 GB" "7e+14 GB" "7e+14 GB" "9e+14 GiB" "9e+14 GiB" "9e+14 GiB" +[10,] "8e+17 GB" "8e+17 GB" "8e+17 GB" "6e+17 GiB" "6e+17 GiB" "6e+17 GiB" + [,7] [,8] [,9] + [1,] "5e-10 G" "5e-10 G" "5e-10 G" + [2,] "6e-07 G" "6e-07 G" "6e-07 G" + [3,] "7e-04 G" "7e-04 G" "7e-04 G" + [4,] "8e-01 G" "8e-01 G" "8e-01 G" + [5,] "3e+02 G" "3e+02 G" "3e+02 G" + [6,] "7e+05 G" "7e+05 G" "7e+05 G" + [7,] "8e+08 G" "8e+08 G" "8e+08 G" + [8,] "5e+11 G" "5e+11 G" "5e+11 G" + [9,] "9e+14 G" "9e+14 G" "9e+14 G" +[10,] "6e+17 G" "6e+17 G" "6e+17 G" +> +> # Single unit, specify digits +> cbind(humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=7), ++ humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=3), ++ humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=2), ++ humanReadable(x=SI1, units="GB", standard="SI", width=NULL, digits=1), ++ humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=7), ++ humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=3), ++ humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=2), ++ humanReadable(x=IEC1, units="GiB", standard="IEC", width=NULL, digits=1), ++ humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=7), ++ humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=3), ++ humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=2), ++ humanReadable(x=IEC1, units="G", standard="Unix", width=NULL, digits=1) ++ ) + [,1] [,2] [,3] [,4] + [1,] "5.000000e-10 GB" "5.00e-10 GB" "5.0e-10 GB" "5e-10 GB" + [2,] "6.388137e-07 GB" "6.39e-07 GB" "6.4e-07 GB" "6e-07 GB" + [3,] "7.101117e-04 GB" "7.10e-04 GB" "7.1e-04 GB" "7e-04 GB" + [4,] "8.188110e-01 GB" "8.19e-01 GB" "8.2e-01 GB" "8e-01 GB" + [5,] "6.706597e+02 GB" "6.71e+02 GB" "6.7e+02 GB" "7e+02 GB" + [6,] "8.067884e+05 GB" "8.07e+05 GB" "8.1e+05 GB" "8e+05 GB" + [7,] "7.758668e+08 GB" "7.76e+08 GB" "7.8e+08 GB" "8e+08 GB" + [8,] "7.861707e+11 GB" "7.86e+11 GB" "7.9e+11 GB" "8e+11 GB" + [9,] "7.495958e+14 GB" "7.50e+14 GB" "7.5e+14 GB" "7e+14 GB" +[10,] "7.655714e+17 GB" "7.66e+17 GB" "7.7e+17 GB" "8e+17 GB" + [,5] [,6] [,7] [,8] + [1,] "4.656613e-10 GiB" "4.66e-10 GiB" "4.7e-10 GiB" "5e-10 GiB" + [2,] "6.058649e-07 GiB" "6.06e-07 GiB" "6.1e-07 GiB" "6e-07 GiB" + [3,] "7.437373e-04 GiB" "7.44e-04 GiB" "7.4e-04 GiB" "7e-04 GiB" + [4,] "7.890501e-01 GiB" "7.89e-01 GiB" "7.9e-01 GiB" "8e-01 GiB" + [5,] "2.665461e+02 GiB" "2.67e+02 GiB" "2.7e+02 GiB" "3e+02 GiB" + [6,] "6.781352e+05 GiB" "6.78e+05 GiB" "6.8e+05 GiB" "7e+05 GiB" + [7,] "7.658425e+08 GiB" "7.66e+08 GiB" "7.7e+08 GiB" "8e+08 GiB" + [8,] "4.681329e+11 GiB" "4.68e+11 GiB" "4.7e+11 GiB" "5e+11 GiB" + [9,] "8.705167e+14 GiB" "8.71e+14 GiB" "8.7e+14 GiB" "9e+14 GiB" +[10,] "6.227605e+17 GiB" "6.23e+17 GiB" "6.2e+17 GiB" "6e+17 GiB" + [,9] [,10] [,11] [,12] + [1,] "4.656613e-10 G" "4.66e-10 G" "4.7e-10 G" "5e-10 G" + [2,] "6.058649e-07 G" "6.06e-07 G" "6.1e-07 G" "6e-07 G" + [3,] "7.437373e-04 G" "7.44e-04 G" "7.4e-04 G" "7e-04 G" + [4,] "7.890501e-01 G" "7.89e-01 G" "7.9e-01 G" "8e-01 G" + [5,] "2.665461e+02 G" "2.67e+02 G" "2.7e+02 G" "3e+02 G" + [6,] "6.781352e+05 G" "6.78e+05 G" "6.8e+05 G" "7e+05 G" + [7,] "7.658425e+08 G" "7.66e+08 G" "7.7e+08 G" "8e+08 G" + [8,] "4.681329e+11 G" "4.68e+11 G" "4.7e+11 G" "5e+11 G" + [9,] "8.705167e+14 G" "8.71e+14 G" "8.7e+14 G" "9e+14 G" +[10,] "6.227605e+17 G" "6.23e+17 G" "6.2e+17 G" "6e+17 G" +> +> +> stopifnot( is.object_sizes(as.object_sizes( 2^(1:30) ) ) ) +> stopifnot( format(as.object_sizes(124)) == "124 bytes") +> stopifnot( format(as.object_sizes(124e8), units="auto") == "11.5 GiB") +> stopifnot( format(as.object_sizes(124e8), humanReadable=TRUE) == "11.5 GiB") +> stopifnot( format(as.object_sizes(124e8), units="bytes") == "1.24e+10 bytes") +> +> tools::assertError( as.object_sizes(-1) ) +> tools::assertError( as.object_sizes('a') ) +> tools::assertError( as.object_sizes(list()) ) +> tools::assertError( as.object_sizes(NULL) ) +> tools::assertError( as.object_sizes(0+1i) ) +> +> stopifnot( format(as.object_sizes(1e40) ) == "1e+40 bytes" ) +> stopifnot( format(as.object_sizes(1e40), units="auto" ) == "8.271806e+15 YiB") +> stopifnot( format(as.object_sizes(1e40), units="bytes") == "1e+40 bytes" ) +> stopifnot( format(as.object_sizes(1e40), humanReadable=TRUE) == "8.271806e+15 YiB") +> stopifnot( format(as.object_sizes(1e40), humanReadable=FALSE) == "1e+40 bytes") +> +> options(humanReadable=TRUE) +> stopifnot( format(as.object_sizes(1e40) ) == "8.271806e+15 YiB") +> options(humanReadable=FALSE) +> +> proc.time() + user system elapsed + 0.411 0.048 0.455 This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-25 02:52:55
|
Revision: 1956 http://sourceforge.net/p/r-gregmisc/code/1956 Author: warnes Date: 2015-04-25 02:52:53 +0000 (Sat, 25 Apr 2015) Log Message: ----------- Add error message if Excel file format is too old Modified Paths: -------------- trunk/gdata/inst/perl/Spreadsheet/ParseExcel.pm Modified: trunk/gdata/inst/perl/Spreadsheet/ParseExcel.pm =================================================================== --- trunk/gdata/inst/perl/Spreadsheet/ParseExcel.pm 2015-04-23 22:59:23 UTC (rev 1955) +++ trunk/gdata/inst/perl/Spreadsheet/ParseExcel.pm 2015-04-25 02:52:53 UTC (rev 1956) @@ -1659,9 +1659,14 @@ $iFillP, $iFillCF, $iFillCB ); + if ( $oBook->{BIFFVersion} == verBIFF2 ) { + die "Unsupported file format: Excel Version 2.0 (4.0 or later required)"; + } + elsif ( $oBook->{BIFFVersion} == verBIFF3 ) { + die "Unsupported file format: Excel Version 3.0 (4.0 or later required)"; + } + elsif ( $oBook->{BIFFVersion} == verBIFF4 ) { - if ( $oBook->{BIFFVersion} == verBIFF4 ) { - # Minimal support for Excel 4. We just get the font and format indices # so that the cell data value can be formatted. ( $iFnt, $iIdx, ) = unpack( "CC", $sWk ); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <wa...@us...> - 2015-04-23 22:59:26
|
Revision: 1955 http://sourceforge.net/p/r-gregmisc/code/1955 Author: warnes Date: 2015-04-23 22:59:23 +0000 (Thu, 23 Apr 2015) Log Message: ----------- Update NEWS and ChangeLog Modified Paths: -------------- trunk/gplots/inst/ChangeLog trunk/gplots/inst/NEWS Modified: trunk/gplots/inst/ChangeLog =================================================================== --- trunk/gplots/inst/ChangeLog 2015-04-23 22:55:43 UTC (rev 1954) +++ trunk/gplots/inst/ChangeLog 2015-04-23 22:59:23 UTC (rev 1955) @@ -1,5 +1,8 @@ 2015-04-23 warnes + * [r1954] DESCRIPTION, R/heatmap.2.R, inst/ChangeLog, inst/NEWS: In + heatmap.2(), the color key now properly handles color breaks that + are not equally spaced. (Issue reported by Tim Richter-Heitmann.) * [r1948] R/plotCI.R: - plotCI() was not properly respecting the 'type=' argument. This has been corrected. Modified: trunk/gplots/inst/NEWS =================================================================== --- trunk/gplots/inst/NEWS 2015-04-23 22:55:43 UTC (rev 1954) +++ trunk/gplots/inst/NEWS 2015-04-23 22:59:23 UTC (rev 1955) @@ -4,7 +4,8 @@ New Features: - heatmap.2() has two new arguments, 'colRow' and 'colCol' to control - the color of row and column text labels. + the color of row and column text labels. See the man page for + examples. - heatmap.2() has been modified to make it easier to extract and plot subclusters from a large heatmap. Simply pass the dendrogram of the @@ -18,18 +19,17 @@ Bug Fixes: +- In heatmap.2(), the color key now properly handles color breaks that + are not equally spaced. (Issue reported by Tim Richter-Heitmann.) + - plotCI() now properly respects the 'type=' argument. (Bug report and correction by Wiktor Żelazny.) - Remove stray browser() call from overplot() -- In the balloonplot() examples, explicitly specify argument to - gplots:::reorder.factor to prevent error. +- In the balloonplot() examples, explicitly specify the 'neworder' + argument to gplots:::reorder.factor to prevent errors. -Other Changes: - -- Remove stray browser() call from - Release 2.16.0 - 2015-01-02 --------------------------- This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |