Commit a6bbe9c6 authored by Nicolau Manubens's avatar Nicolau Manubens
Browse files

Removed ncdf4 bugfix.

parent 0324da13
......@@ -3,8 +3,7 @@ Title: Tools to Easily Read/Write NetCDF Files into/from Multidimensional R Arra
Version: 0.0.3
Authors@R: c(
person("BSC-CNS", role = c("aut", "cph")),
person("Nicolau", "Manubens", , "nicolau.manubens@bsc.es", role = c("aut", "cre")),
person("David", "Pierce", , "david.pierce@ucsd.edu", role = c("ctb")))
person("Nicolau", "Manubens", , "nicolau.manubens@bsc.es", role = c("aut", "cre")))
Description: Set of wrappers for the 'ncdf4' package to simplify and extend its reading/writing capabilities into/from multidimensional R arrays.
Depends:
R (>= 2.14.1)
......@@ -16,4 +15,3 @@ URL: https://earth.bsc.es/gitlab/es/easyNCDF/wikis/home
BugReports: https://earth.bsc.es/gitlab/es/easyNCDF/issues
LazyData: true
SystemRequirements: netcdf development libraries
NeedsCompilation: yes
useDynLib(easyNCDF)
exportPattern("^[^\\.]")
import(ncdf4, abind)
importFrom("stats", "setNames")
......@@ -203,8 +203,8 @@ NcToArray <- function(file_to_read, dim_indices = NULL, vars_to_read = NULL,
(length(file_object[['var']][[var_name]][['dim']]) > 1)) {
start <- c(1, start)
count <- c(-1, count)
##original_ncvar_get_inner <- ncdf4:::ncvar_get_inner
##assignInNamespace('ncvar_get_inner', .ncvar_get_inner, 'ncdf4')
## original_ncvar_get_inner <- ncdf4:::ncvar_get_inner
## assignInNamespace('ncvar_get_inner', .ncvar_get_inner, 'ncdf4')
}
var_result <- do.call('[', c(list(.ncvar_get(file_object, var_name, start, count, collapse_degen = FALSE)),
lapply(indices_to_take, function(x) if (is_single_na(x)) TRUE else x - min(x) + 1), list(drop = FALSE)))
......
This diff is collapsed.
#! /bin/sh
rm -f config.* R/load.R src/Makevars
rm -rf autom4te.cache
This diff is collapsed.
##PKG_CPPFLAGS=-I/path/to/netcdf/header
##PKG_LIBS=-L/path/to/netcdf/lib -lnetcdf
PKG_LIBS=@NETCDF_LDFLAGS@
PKG_CPPFLAGS=@NETCDF_CPPFLAGS@
PKG_LIBS = -lnetcdf4 -L$(LIB_HDF5)/lib${R_ARCH} -lhdf5_hl -lhdf5 -lz
This diff is collapsed.
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment