Thank you JJ and Dirk, For whatever it's worth, I had already pulled the
attributes vignette and read it multiple times before making a posting. I
found the vignette to be very clear until the section on working under
packages. As mentioned, I had some difficulty to discern the old-to-new
compar
> All to say, it is unclear to me whether the intended use of
> compileAttributes() is solely to help package writers allow package users
> to more easily access the c++ functions at the R layer or additionally to
> also streamline how package developers source c++ files within their own
> package
On 21 November 2012 at 18:36, terrance savitsky wrote:
| Hi, I've read this note a few times and still find myself similarly confused.
Maybe you could take a look at the seven page vignette 'Rcpp-attribute' which
came with your copy of Rcpp 0.10.0.
It should answers these questions of yours.
Hi, I've read this note a few times and still find myself similarly
confused. Does the new compileAttributes() for //[[Rcpp::export]] tagged
functions intend to provide a more streamlined alternative to employment of
RcppExport inclusions in declarations in the header file and subsequent
use of
> > I mean, the .h and *.R files generated with Rcpp.package.skeleton seem to
> > have a simple structure that I find easy to replicate and modify as I keep
> > adding stuff to my *.cpp file. (For instance, the placement of RccpExport
> > before functions intended to be exported, the usage of S
I think it is just I did something wrong with installing Rcpp from
source, which I cannot reproduce now.
Thanks very much.
--
Jiqiang
On Thu, Nov 15, 2012 at 1:55 PM, Dirk Eddelbuettel wrote:
> Possibly a non-standard Rcpp installation?
___
Rcpp-devel
> 1. Suggestion: it might be appropriate to say (probably before 5.1) that
> Makevars, etc, are still needed. And, thus, point the reader to
> vignette("Rcpp-package").
>
Very good suggestion -- will do!
> I mean, the .h and *.R files generated with Rcpp.package.skeleton seem to
> have a simple
Dear Dirk, Romain, and JJ,
Version 0.10 is really amazing. In particular, the Rcpp Attributes are
awesome, as well as some of the additions to sugar!!
If I may, I'd like to make a suggestion and a question about the
documentation for Rcpp Attributes.
1. Suggestion: it might be appropriate to
On 15 November 2012 at 13:42, JJ Allaire wrote:
| The error appears to be occurring in the call to RcppLdPath (made by both
| sourceCpp and RStan). Here's the source code for that function:
|
| RcppLdPath <- function() {
| if (nzchar(.Platform$r_arch)) { ## eg amd64, ia64, mips
| path
On 15 November 2012 at 13:40, Jiqiang Guo wrote:
| Thanks.
|
| The same error if I use cppFunction thought the example in sourceCpp
| use a string of c++ code passed using code:
Oh, sorry, my bad -- was short of time and couldn;t test, and don't even have
a mac. I will let the mac squad get to
I see. For some reason, my installing Rcpp from source last time did
not install the 64 bits lib, so
Rcpp.system.file("lib", .Platform$r_arch) for me returns "".
I reinstalled Rcpp 0.10.0 from source and made sure lib/x86_64 exists, then
everything is fine.
Thanks.
--
Jiqiang
On Thu, Nov 15, 2
The error appears to be occurring in the call to RcppLdPath (made by both
sourceCpp and RStan). Here's the source code for that function:
RcppLdPath <- function() {
if (nzchar(.Platform$r_arch)) { ## eg amd64, ia64, mips
path <- Rcpp.system.file("lib",.Platform$r_arch)
} else {
Thanks.
The same error if I use cppFunction thought the example in sourceCpp
use a string of c++ code passed using code:
> require(Rcpp)
>
> cppFunction(code='
+#include
+
+// [[Rcpp::export]]
+int fibonacci(const int x) {
+ if (x == 0) return(0);
+
On 15 November 2012 at 13:20, Jiqiang Guo wrote:
| I tried the example of sourceCpp on Mac mountain lion with R 2.15.1
| with the following error (I hit the similar error in using RStan as
| well).
|
| > library(Rcpp)
| > require(Rcpp)
| >
| > sourceCpp(code='
Operator error: sourceCpp() t
Thanks.
But I am using R from command line, and I think it is set correctly:
> Sys.getenv("R_ARCH")
[1] "/x86_64"
--
Jiqiang
On Thu, Nov 15, 2012 at 1:30 PM, JJ Allaire wrote:
>
>
> On Thu, Nov 15, 2012 at 1:20 PM, Jiqiang Guo wrote:
>>
>> I tried the example of sourceCpp on Mac mountain lion
On Thu, Nov 15, 2012 at 1:20 PM, Jiqiang Guo wrote:
> I tried the example of sourceCpp on Mac mountain lion with R 2.15.1
> with the following error (I hit the similar error in using RStan as
> well).
>
I think the common problem here might be whether R_ARCH is set correctly.
On the Mac R_ARCH n
I tried the example of sourceCpp on Mac mountain lion with R 2.15.1
with the following error (I hit the similar error in using RStan as
well).
> library(Rcpp)
> require(Rcpp)
>
> sourceCpp(code='
+#include
+
+// [[Rcpp::export]]
+int fibonacci(const int x) {
+
17 matches
Mail list logo