From 4f345bc90f7b1c64ef3ed8c396091e8134a39ba2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20N=C3=BCst?= Date: Thu, 26 Feb 2015 09:49:25 +0100 Subject: [PATCH 1/3] fix typo --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index be3410a..be42d81 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ Futher user documentation is in the R help and the vignettes: ```r vignette(package = "sensorweb4R") -vignette("") ``` ### Developers From 315c2ea864e288ad086c34e7fe89a661d38b8782 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20N=C3=BCst?= Date: Thu, 26 Feb 2015 13:05:28 +0100 Subject: [PATCH 2/3] add note about generation of reference manual to readme --- README.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/README.md b/README.md index b06f773..b5d021b 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,12 @@ vignette(package = "sensorweb4R") vignette("") ``` +When installed from source or GitHub, run the command [Rd2pdf](http://cran.r-project.org/doc/manuals/R-exts.html#index-R-CMD-Rd2pdf) in the parent directory of the package to create the reference manual, which describes all functions in the package: + +``` +R CMD Rd2pdf sensorweb4R +``` + ## Development ### Building the documentation From 673f4ad3477980d4be925d29911f066fb5677a5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20N=C3=BCst?= Date: Thu, 26 Feb 2015 14:30:23 +0100 Subject: [PATCH 3/3] fix some R CMD check warnings --- DESCRIPTION | 5 ++++- NAMESPACE | 1 + R/distance-matrix.R | 1 - R/utils.R | 4 ++-- R/zzz.R | 1 + 5 files changed, 8 insertions(+), 4 deletions(-) diff --git a/DESCRIPTION b/DESCRIPTION index b3a8264..3896951 100644 --- a/DESCRIPTION +++ b/DESCRIPTION @@ -1,10 +1,12 @@ Package: sensorweb4R Title: Connect R to the Sensor Web Client API for downloading timeseries data. Version: 0.1 +Encoding: UTF-8 Authors@R: c( person("Daniel", "Nuest", email = "d.nuest@52north.org", role = + c("aut")), person("Christian", "Autermann", email = "c.autermann@52north.org", role = c("aut", "cre")), person("52\u00b0North", email = "info@52north.org", role = c("cph"), comment = "This package is part of a managed codebase.") ) -Description: An R client for the 52\u00b0North Sensor Web Client API +Description: An R client for the 52North Sensor Web Client API Depends: R (>= 3.1.1) License: Apache License (== 2.0) | file LICENSE @@ -12,6 +14,7 @@ LazyData: true URL: https://github.com/52North/sensorweb4R BugReports: https://github.com/52North/sensorweb4R/issues Imports: + methods, futile.logger, httr, sp, diff --git a/NAMESPACE b/NAMESPACE index badc6d5..a8a9a9a 100644 --- a/NAMESPACE +++ b/NAMESPACE @@ -216,6 +216,7 @@ exportClasses(TVP) exportClasses(Timeseries) exportMethods(length) import(futile.logger) +import(methods) import(sp) import(stats) import(xts) diff --git a/R/distance-matrix.R b/R/distance-matrix.R index e1529a2..5797754 100644 --- a/R/distance-matrix.R +++ b/R/distance-matrix.R @@ -194,7 +194,6 @@ setGeneric("distanceMatrix", function(x, ...) setMethod("distanceMatrix", signature(x = "SpatialPoints"), function(x, ...) { - require(geosphere) n <- length(x) dm <- matrix(0, ncol=n, nrow=n) for (i in 1:n) { diff --git a/R/utils.R b/R/utils.R index c15cd61..0f42306 100644 --- a/R/utils.R +++ b/R/utils.R @@ -31,7 +31,7 @@ license_header <- function(pkg = ".", header = "inst/license-header", add = FALS stop("devtools required to run license_header(). Please install.", call. = FALSE) } - files <- devtools::find_code(devtools:::as.package(pkg)) + files <- devtools:::find_code(devtools::as.package(pkg)) flog.debug("Checking license headers of %s files using '%s', adding if missing = %s", length(files), header, add) .result <- .addLicenseHeaderToFiles(files, header, add) @@ -80,7 +80,7 @@ has_license_header <- function(pkg = ".", header = "inst/license-header") { files_missing_header <- list() - headerConn <- file(file.path(devtools:::as.package(".")$path, header), 'r+') + headerConn <- file(file.path(devtools::as.package(".")$path, header), 'r+') header_content <- readLines(headerConn) close(headerConn) flog.trace("Header: %s", paste(header_content, sep = "", collapse = "")) diff --git a/R/zzz.R b/R/zzz.R index 58c9a96..676db66 100644 --- a/R/zzz.R +++ b/R/zzz.R @@ -44,6 +44,7 @@ #' @import futile.logger #' @keywords ts, spatial #' @concept sensorweb, timeseries +#' @import methods NULL # documenting null to integrate this comment into a specific rd file via @name, see http://r-pkgs.had.co.nz/man.html#dry2 # when you change .onLoad and .onAttach functions, don't forget to call load_all with reset=TRUE !