Re: [R-pkg-devel] how is RData in /data understood

2019-01-22 Thread Uwe Ligges
You have to document each data object, but there can be multiple objects 
in an .RData file.


So for foo.RData the call data(foo) could make several objects 
available, each of which has to be docuemnted.


Not sure about Hadley's book, nor roxygen, nor RSTudio, as I'd do all 
this in plain R.


Best,
Uwe Ligges


On 22.01.2019 15:58, Troels Ring wrote:

Dear friends - I noticed in Hadley Wickham's comprehensive book on packages
under "exported data" that the .RData file in data directory is "containing
a single object (with the same name as the file)". However, in the "Writing
R extensions" 1.1.6 - when discussing images created by save there is no
statement I can see that the RData should only contain a single object? Is
that common knowledge?

I got a  problem when adding the code below to an otherwise well working
datasets.R in R directory - wonder if it is connected to the above since
Baaeza.RData contains multiple objects.

  


#' routine for multiequilibrium problems

#'

#' @description Data from Baeza-Baeza et al.

#'

#' @format A worksheet.

#' \describe{

#'  \item{Na}{Strong ions}

#' }

#'

#' @examples

#' data(Baeza)

#'

"Baeza"

  


And even though I have Baeza.RData in the /data directory ctrl-shift-B
stopped immediately with

Updating acidcharge documentation

Loading acidcharge

error: 'baeza' is not exported object from 'namespace:acidcharge'

run stopped

  


Exited with status 1

Best wishes

Troels


[[alternative HTML version deleted]]

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel



__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


[R-pkg-devel] how is RData in /data understood

2019-01-22 Thread Troels Ring
Dear friends - I noticed in Hadley Wickham's comprehensive book on packages
under "exported data" that the .RData file in data directory is "containing
a single object (with the same name as the file)". However, in the "Writing
R extensions" 1.1.6 - when discussing images created by save there is no
statement I can see that the RData should only contain a single object? Is
that common knowledge?

I got a  problem when adding the code below to an otherwise well working
datasets.R in R directory - wonder if it is connected to the above since
Baaeza.RData contains multiple objects.

 

#' routine for multiequilibrium problems

#'

#' @description Data from Baeza-Baeza et al.

#'

#' @format A worksheet.

#' \describe{

#'  \item{Na}{Strong ions}

#' }

#'

#' @examples

#' data(Baeza)

#'

"Baeza"

 

And even though I have Baeza.RData in the /data directory ctrl-shift-B
stopped immediately with

Updating acidcharge documentation

Loading acidcharge

error: 'baeza' is not exported object from 'namespace:acidcharge'

run stopped

 

Exited with status 1

Best wishes

Troels


[[alternative HTML version deleted]]

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel