<div dir="ltr">Or -- in all our spare time! -- we should really consider doing the right thing and Rcpp-ifying the bigmemory packages.  It's probably too late for a GSOC project at this point.  Mike and I will talk about it.  If we think we could manage it over 2-3 intense days, maybe it will happen this summer.<div>
<br></div><div>Jay</div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Apr 12, 2013 at 5:47 AM, JJ Allaire <span dir="ltr"><<a href="mailto:jj.allaire@gmail.com" target="_blank">jj.allaire@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">Alex,</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">
<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">
Glad that you sorted all of this out! Wanted to also point out that there is a mechanism for bigmemory to have it's headers automatically included in RcppExports.cpp and perhaps this is something Michael can pursue so everything works automatically in the future. </div>

<div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">In short, if bigmemory defines an Rcpp inline plugin (by calling Rcpp.plugin.maker) that lists the includes required for correct compilation then these includes will be inserted at the top of RcppExports.cpp. Michael, ping me off list if you have any questions or want to discuss further.</div>

<div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">J.J.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif">

<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif"><br></div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Apr 11, 2013 at 5:44 PM, Alex Ustian <span dir="ltr"><<a href="mailto:alex.l.ustian@gmail.com" target="_blank">alex.l.ustian@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">All right!  I think I have it figured out, at least for the toy functions/package.  <br><div><br>What wasn't compiling wasn't my functions, it was RcppExports.cpp.  sourceCpp (and hence also the knit example) have been working for me all along.  The only issue (apparently) was that RcppExports.cpp was not including the bigmemory headers.  It complained about not knowing the type "BigMatrix" for example.  However since RcppExports.cpp is automatically generated, I didn't know how to force it to include more headers.  <br>


<br>It dawned on me that somewhere in the Rcpp-attributes vignette creating custom headers came up, sure enough using // [[Rcpp::interfaces(r, cpp)]] and following along in that section 3.5 discussion and then rebuilding did the trick.  In the end I just I added the required bigmemory header "MatrixAccessor.hpp" to the generated "package.h" file, which is then automatically included into the RcppExports.cpp file.<br>


<br>Thanks again, and thanks everybody for developing and providing support for this incredible software.<span><font color="#888888"><br>Alex<br></font></span></div></div><div><div>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Thu, Apr 11, 2013 at 4:33 PM, Dirk Eddelbuettel <span dir="ltr"><<a href="mailto:edd@debian.org" target="_blank">edd@debian.org</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><br>
<br>
On 11 April 2013 at 16:14, Alex Ustian wrote:<br>
| Sorry to be dense, but you mean to copy and paste the source into an Rmd file<br>
| and knit it?  If yes, then I did just that and it did work.<br>
<br>
</div>Good.<br>
<br>
Now try to find the differences to your code, which as I understand your<br>
post, does not compile.  As you just demonstrated that your compiler, R, Rcpp,<br>
bigmemory, ... setup is fine.<br>
<div><div><br>
Dirk<br>
<br>
--<br>
Dirk Eddelbuettel | <a href="mailto:edd@debian.org" target="_blank">edd@debian.org</a> | <a href="http://dirk.eddelbuettel.com" target="_blank">http://dirk.eddelbuettel.com</a><br>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
Rcpp-devel mailing list<br>
<a href="mailto:Rcpp-devel@lists.r-forge.r-project.org">Rcpp-devel@lists.r-forge.r-project.org</a><br>
<a href="https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel" target="_blank">https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/rcpp-devel</a><br></blockquote></div><br><br clear="all"><div>
<br></div>-- <br>John W. Emerson (Jay)<br>Associate Professor of Statistics, Adjunct, and Director of Graduate Studies<br>Department of Statistics<br>Yale University<br><a href="http://www.stat.yale.edu/~jay" target="_blank">http://www.stat.yale.edu/~jay</a>
</div>