[R] Only referenc copy when calling C routine?
andy_liaw at merck.com
Mon Apr 12 03:25:13 CEST 2004
My understanding is that if DUP=FALSE, no copying is done in either
If you want to avoid copying, the .Call interface is probably more suitable,
as you pass the actual R objects to the C function. I'm not familiar with
> From: Shin, Daehyok [mailto:sdhyok at email.unc.edu]
> Thanks, Andy.
> Let me ask a little more about the DUP argument.
> In the manual, I can see that only reference copy happens
> when passing an
> if DUP=FALSE. Then, what happens when returning it in a list,
> if DUP=FALSE?
> Another reference copy, or deep copy?
> I am trying to implement a dynamic modeling system in R,
> where some C functions should be called more than 1000 times
> with arguments
> of huge arrays.
> So, the issue is important for better performance.
> Thanks again,
> Daehyok Shin
More information about the R-help