Re: [Rd] create R package include Fortran source code.

2014-07-21 Thread Charles Berry
yiqun yang gmail.com> writes: > > Thank you for your reply. > First I try "R CMD INSTALL barpkg", then it gives similiar things: > - [deleted] - > 2) I don't know how to chec

Re: [Rd] create R package include Fortran source code.

2014-07-21 Thread yiqun yang
Thank you for your reply. First I try "R CMD INSTALL barpkg", then it gives similiar things: - * installing *source* package 'barpkg' ... ** libs *** arch - i

Re: [Rd] Licence for datasets in a R-package

2014-07-21 Thread Gábor Csárdi
On Mon, Jul 21, 2014 at 1:56 PM, Gabor Grothendieck wrote: > On Mon, Jul 21, 2014 at 12:54 PM, Gábor Csárdi wrote: >> In practice, CRAN maintainers do not allow multiple licenses for parts >> of the same package. At least they did not for my package a couple of >> months ago. >> > > If that is th

Re: [Rd] Licence for datasets in a R-package

2014-07-21 Thread Gabor Grothendieck
On Mon, Jul 21, 2014 at 12:54 PM, Gábor Csárdi wrote: > In practice, CRAN maintainers do not allow multiple licenses for parts > of the same package. At least they did not for my package a couple of > months ago. > If that is the case then you could put your data files in a separate package from

Re: [Rd] Licence for datasets in a R-package

2014-07-21 Thread Gábor Csárdi
On Mon, Jul 21, 2014 at 12:49 PM, Duncan Murdoch wrote: [...] > If you are not distributing the package to anyone else, you can ignore the > warning about the bad license field. > > If you plan to distribute it on a public repository, you should ask the > policies of the repository to find out wha

Re: [Rd] Licence for datasets in a R-package

2014-07-21 Thread Duncan Murdoch
On 21/07/2014 12:17 PM, Gionata Bocci wrote: Dear List, I am building a R package which collects ecological data about plant species from both remote (web) databases and locally stored rda files (datasets): these "local rda files" are derived from publicly available databases for which no

Re: [Rd] create R package include Fortran source code.

2014-07-21 Thread Duncan Murdoch
On 21/07/2014 12:10 PM, yiqun yang wrote: Hello, all I am building a R package using Fortran source code. The Fortran code is a subroutine. I can use "R CMD SHLIB bar.f -o bar.o" to create the shared library. For the R package, I put the fortran file in the src/ and I use R code as follows: ".

[Rd] Licence for datasets in a R-package

2014-07-21 Thread Gionata Bocci
Dear List, I am building a R package which collects ecological data about plant species from both remote (web) databases and locally stored rda files (datasets): these "local rda files" are derived from publicly available databases for which no "official" licenses are provided; I was told by t

[Rd] create R package include Fortran source code.

2014-07-21 Thread yiqun yang
Hello, all I am building a R package using Fortran source code. The Fortran code is a subroutine. I can use "R CMD SHLIB bar.f -o bar.o" to create the shared library. For the R package, I put the fortran file in the src/ and I use R code as follows: ".First.lib"<-function(libname,pkgname){librar

Re: [Rd] Question on Code snippet semantics

2014-07-21 Thread William Dunlap
subsitute(expr), with only one argument, is only useful inside of a function and then only when the expression, expr, involves an argument to the function. Then the unevaluated actual arguments to the function are substituted into the [unevaluated] expression. E.g., f <- function(x, y=stop("y

Re: [Rd] Question on Code snippet semantics

2014-07-21 Thread Marc Schwartz
On Jul 21, 2014, at 10:07 AM, Mick Jordan wrote: > I came across this code in library.R > > package <- as.character(substitute(package)) > > where package is the first argument to the "library" function. > > I've been racking my brains to understand why this is not just an elaborate > (and i

[Rd] Question on Code snippet semantics

2014-07-21 Thread Mick Jordan
I came across this code in library.R package <- as.character(substitute(package)) where package is the first argument to the "library" function. I've been racking my brains to understand why this is not just an elaborate (and ineffcient) way to write: package <- "package" E.g. > package <-

[Rd] Multiple versions of data in a package

2014-07-21 Thread Chris Wallace
Dear R-devel, I am writing for help on how I should include parallel sets of data in my package. Brief summary: I am new to using data within packages. I want a user to be able to specify one of two alternative versions of within-package datasets to use, and I want to load just that one. I

[Rd] Displaying database records returned from postgresql to R through Java

2014-07-21 Thread Jason Donnald
Hi All, I have a R script which returns a set of records from the postgresql to the Java program and I want to print those records in Java.My script is like this: library(RPostgreSQL) fnct1 <- function() { drv <- dbDriver("PostgreSQL") r <- dbConnect(drv, host='local',