Displaying 20 results from an estimated 500 matches similar to: "Transferring ownership of R-managed buffer"
2017 Mar 29
2
Transferring ownership of R-managed buffer
http://www.keittlab.org/
On Wed, Mar 29, 2017 at 1:04 PM, Herv? Pag?s <hpages at fredhutch.org> wrote:
> Hi Tim,
>
> On 03/29/2017 08:24 AM, Tim Keitt wrote:
>
>> I have a use case where I would like to create an SEXP around an existing
>> buffer that is managed by R, thus avoiding a copy operation.
>>
>
> What to you mean exactly by "an existing
2017 Mar 29
0
Transferring ownership of R-managed buffer
Hi Tim,
On 03/29/2017 08:24 AM, Tim Keitt wrote:
> I have a use case where I would like to create an SEXP around an existing
> buffer that is managed by R, thus avoiding a copy operation.
What to you mean exactly by "an existing buffer managed by R"?
> If I have
> something like:
>
> void *p = (void*) RAW(PROTECT(Rf_allocVector(RAWSXP, n)));
> ... additional
2017 Mar 29
0
Transferring ownership of R-managed buffer
Tim,
What you're describing is a special case of the ALTREP framework/API that
Luke Tierney, Tomas Kalibera, and I are working on putting into R. See my
initial proposal to the DSC here:
https://www.r-project.org/dsc/2016/slides/customvectors.html and the
subsequent branch here: https://svn.r-project.org/R/branches/ALTREP/ where
Luke and I have merged the ideas from that proposal with work he
2017 Mar 30
2
Transferring ownership of R-managed buffer
On Wed, Mar 29, 2017 at 4:56 PM, Gabriel Becker <gmbecker at ucdavis.edu>
wrote:
> The concept of having a vector which is a "window" into another vector
> without duplication ( which I suspect is at least related to your use-case,
> though I could be wrong) is a special case of one of alt-representations I
> have implemented there.
>
Nice. That is exactly what I
2014 Oct 22
2
Using a custom memory allocation function in R
Heads up: I posted this question on Stackoverflow yesterday
(http://stackoverflow.com/questions/26484103/using-a-custom-memory-allocation-function-in-r).
So far I haven?t gotten a response and I thought this could be an even
better place to ask such a question.
I would like to be able to use my own memory allocation function for
certain data structures (real valued vectors and arrays) in R. The
2008 Apr 03
2
g++ 4.3 warning: deprecated conversion from string constant to ‘char*’
Hello,
I've noticed that with g++ 4.3 I get the following "warning: deprecated
conversion from string constant to ?char*?" when I call e.g.,
Rprintf("Hello world"); or when I try to define a const char e.g., char
lower = 'L';
I am wrapping the c++ code in extern "C" {}. This seems to be something
new with g++ 4.3, because the same code compiled
2004 Feb 17
2
interfacing C++ using .Call
Hi folks,
I apologise if this is in the documentation somewhere, but I can't
seem to find it. I also did a search of CRAN without any success. I'm
using R-1.8.1 (pre-compiled) on Windows 2000 with Rtools and mingw 2.0.0
(which includes gcc/g++ 3.2).
I'm trying to link some C++ code from another application to R using the
.Call interface and am experiencing some problems. I was
2005 Apr 25
1
Failed to install gbm_1.4-2 (PR#7814)
Full_Name: The Manager
Version: 2.0.1
OS: Solaris 9
Submission from: (NULL) (129.67.80.243)
> install.packages("gbm")
trying URL `http://cran.uk.r-project.org/src/contrib/PACKAGES'
Content type `text/plain; charset=ISO-8859-1' length 52975 bytes
opened URL
==================================================
downloaded 51Kb
trying URL
2011 Aug 13
1
Latent flaw in SEXPREC definition
There seems to be a latent flaw in the definition of struct SEXPREC
in Rinternals.h, which likely doesn't cause problems now, but could
if the relative sizes of data types changes.
The SEXPREC structure contains a union that includes a primsxp,
symsxp, etc, but not a vecsxp. However, in allocVector in memory.c,
zero-length vectors are allocated using allocSExpNonCons, which
appears to
2010 May 04
1
errors when installing rjags
Hi,
With the sid package jags (2.0.0-1) and r-base-core (2.11.0-1), I cannot
install package rjags anymore (this used to work at some point; can't
recall exactly at what R/JAGS versions):
---<--------------------cut here---------------start------------------->---
R> install.packages("rjags", configure.args="--with-jags-modules=/usr/lib/JAGS/modules-2.0.0")
2009 Oct 04
3
error installing/compiling kernlab
Hi everybody,
I''m using R on a 64-bit Ubuntu 9.04 (Jaunty). I prefer to install R
packages from source, even if they are available in Synaptic. The
problem is that I can''t install/compile kernlab. Everything works fine
until it gets to the lazy loading part:
** preparing package for lazy loading
Creating a new generic function for "terms" in "kernlab"
2008 Feb 19
1
level of mutability for the type of a SEXP
Dear list,
I am writing C code to interface with R, and I would like to know the
level of mutability for the type of a SEXP.
I see that there is a macro/function TYPEOF(), and that it can be used
as an l-value, as well as a macro/function SET_TYPEOF().
My question is "should the type be considered immutable, or it can it
change after the SEXP has been created and used for a while ?".
2016 May 25
3
Suggestion: mkString(NULL) should be NA
On Wed, May 25, 2016 at 7:22 AM, Michael Lawrence <lawrence.michael at gene.com
> wrote:
> On Wed, May 25, 2016 at 4:23 AM, Jeroen Ooms <jeroen.ooms at stat.ucla.edu>
> wrote:
>
I'm not disagreeing with what's been said in this thread, but I can't help
but recall that I brought up this exact issue probably 15 years ago and was
told (by Brian, I believe)
2011 Jan 20
1
Calling C++ from R
Hi All,
I am new to this area and use Rcpp to call C++ from R and try to build the
package under Windows 7. I use Rtools and R 2.10.1 32bit. Everything works
fine with me, except using R functions like "rnorm" or "runif" in the C++
code. When I use "R CMD check" the package, it always return error
** libs
making DLL ...
g++
2009 Jan 05
1
can't get names of R_env
Hi,
I'm quite knew in R, so I might not have the R specific jargon.
But here is my problem,
I'm trying to access and use variabels given by a function environment,
more specifically the rho in do_optim in src/main/optim.c
According to the documentation
http://cran.r-project.org/doc/manuals/R-ints.html#The-_0027data_0027
the envsxp is defined as a tagged pairlist.
"ENVSXP: Pointers
2007 Jun 07
1
Ubu edgy + latest CRAN R + Rmpi = no go
I'm just curious if anyone else has had problems with this
configuration. I added the CRAN repository to apt and installed 2.5.0
with apt-get. I then did an install.packages("Rmpi") on cluster nodes.
Rmpi loads and lamhosts() shows the nodes, but mpi.spawn.Rslaves()
fails (something to do with temp files?). Rmpi works fine with the
Edgy-native version of R (2.3.x) and installing
2012 May 03
1
Setting up a windows system for rcpp
I am running into a wall getting my system to work with rcpp and inline.
Following Dirk's advice on stackoverflow, I hope someone is able to help
me.
My steps were to install MinGW 32 bit first, then installing Rtools, I
disabled MinGW's entry in the PATH.
I am trying to get the following code to work:
library(Rcpp)
library(inline)
body <- '
NumericVector xx(x);
return wrap(
2013 May 14
2
invalid operands of types ‘SEXPREC*’ and ‘R_len_t’ to binary ‘operator/’ with Rcpp.
Dear R-Developers,
I just started learning how to use Rcpp. Earlier while using it, I
encountered an error as shown below:
file74d8254b96d4.cpp: In function ‘Rcpp::NumericVector
foo(Rcpp::NumericVector, Rcpp::NumericVector, Rcpp::NumericVector,
Rcpp::Function, Rcpp::Function)’:
file74d8254b96d4.cpp:10: error: invalid operands of types ‘SEXPREC*’ and
‘R_len_t’ to binary ‘operator/’
make: ***
2008 Mar 11
1
Rtools and GCC4 problem
>>
I am trying to compile rseries from Whit Armstrong and a colleague of mine found
a problem with using GCC4
I get the following error when compiling rseries
g++-sjlj -Ic:/R/include -O2 -Wall -c Rutils.cpp -o Rutils.o
Rutils.cpp: In function 'double* getColPointer(SEXPREC*, int)':
Rutils.cpp:406: warning: deprecated conversion from string constant to 'char*'
2005 Dec 09
3
[R] data.frame() size
Hi,
Please see below for post on r-help regarding data.frame() and the
possibility of dropping rownames, for space and time reasons.
I've made some changes, attached, and it seems to be working well. I see the
expected space (90% saved) and time (10 times faster) savings. There are no
doubt some bugs, and needs more work and testing, but I thought I would post
first at this stage.
Could some