Thank you for your very detailed review and comments.
The package and paper have been updated updated to reflect these suggestions, and the additional documentation is very beneficial.
This reply contains two major section. The first is 'open issues' and addresess items which were brought up as required improvements or changes. The second is 'comments' and either responds to some minor items, or provides other clarification.
R packages need to be loaded, so library("RcppCNPy")
(which is case-sensitive) is indeed
required.
We do have a section in the README.md
showing this as floating point (shown below) and
also integer:
R> library(RcppCNPy)
R> fmat <- npyLoad("fmat.npy")
The package contains a demo file (which can be executed via demo("timings", package="RcppCNPy"
)
showing this, and the vignette also shows it.
To be even more explicit we added this also to the 'Examples' sections of the help pages.
That provides four different instances showing how to load the package and perform a few first steps which should be sufficient for users of the package.
The package already contains tests which are executed each time R CMD check
runs. The
standard R mechanism of using files in the top-level directory tests/
is used.
There are two levels of tests.
Files ending in .Rout.save
provide (persistent) reference output which is compared
character-by-character to freshly created output during a test. Any differences are
reported (but are not fatal).
Additionally, the file tests/loadFiles.R
contains five stopifnot()
tests which would
abort unless the tested condition (of comparing read content to expected content) are met
exactly. That provides stringent unit testing.
It is unclear whether an additional markdown or README file is required as the package conforms to standard R and CRAN practice.
The DESCRIPTION
file lists the standard GitHub facilities:
BugReports: https://github.com/eddelbuettel/rcppcnpy/issues
By being on GitHub and listing the repository, the standard and well-known participation venues offered by GitHub are available.
Following this suggestion, we made this more explicit by adding a short section to the README.md as well.
We added the DOIs (as supplied by the publisher) for one of the two references. The second reference does not yet have a DOI.
We also added the DOI for this submission as a 'badge' to the main README.md
.
The installation command for R is case-sensitive so the most recent released version can be installed via `install.packages("RcppCNPy").
Should this be desired, R also allows installation directly from the GitHub repository by
supplying eddelbuettel/rcppcnpy
as the (unique) 'author/repo' token. But as RcppCNPy is
a CRAN package so we prefer the more common first approach using install.packages()
.
Line 17 of DESCRIPTION
clearly states License: GPL (>= 2)
. This exact form is described in the corresponding R
manuals, and e.g. expands on the
CRAN webpage for the package
to 'GPL-2 | GPL-3'. Both licenses are
OSI approved, and used by R itself in the same form.
The GNU statement was already present at src/cnpyMod.cpp
, the main C++ intgegration
script. Files src/cnpy.cpp
and src/cnpy.h
carry both a statement for the MIT license
of the underlying cnpy library by Rogers, and the a short sentence stating GPL for the
additional integration provided by this package.
The remaining source file R/cnpy.R
is a one-liner so that adding a copyright header
seemed excessive.
In general, code from a vignette can always be extracted via Stangle()
. Here, we chose
to keep the result fixed and static to not endure the (still short) simulation on each
latex-compilation of the vignette. However, the package contains a demo detailing this
which can be seen via demo("timings", package="RcppCNPy")
. It contains the same
benchmark. This permits each user to validate performance locally.
The package provides an input/ouput facility so that R users can read and/or write files in the NumPy format. As such, it the target audience is not restricted to any class or set of users, members of discipline, or methodological school.
The key focus is stated is stated in the package description, in the first full sentence in the README.md, and in the first line of the abstract of the vignette.
As an R package, there should be rather a limited need for the Python specifics particularly as every NumPy version appears to provide the identical output. As such, we have not seen any need to provide more detail.
As an R package, primary documentation is provided via the help pages, and then the vignette. Both detail how to use the package.
Adding .npz
files has long been noted as possible extensions, this is also explicitly
stated in the vignette. Development of the package was needs-driven: we needed to process
certain files, and the npz
was not a format we used. Pull-requests by users with the
need to process such files are therefore strongly encouraged.
The need to explicitly request integer
format is a limitation of the format and the
underlying library. There appears to be no meta-data signalling the content.
I second this recommendation.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.