Displaying 3 results from an estimated 3 matches for "rf_lang1".
Did you mean:
rf_lang2
2012 Apr 16
1
eval a SYMSXP from C
...2.0
xn <- foo(rnorm(100),mu)
> typeof(attr(xn,"mu"))
[1] "symbol"
> eval(attr(xn,"mu"))
[1] 2
>
In a .Call, I am attempting to eval the SYMSXP as follows:
SEXP mu_ = Rf_getAttrib(x_,Rf_install("mu"));
if(TYPEOF(mu_)==SYMSXP) {
mu_ = Rf_eval(Rf_lang1(mu_),R_GlobalEnv);
}
However, when running this code, I get the following error:
Error in logp(xn) : could not find function "mu"
Do I need to create an expression of c("get", "mu") to force the name
lookup to evaluate the SYMSXP?
Thanks,
Whit
2011 Jan 11
0
[Rcpp-devel] Loading a package using Rcpp Modules results in memory corruption
...t;>>>> much for
>>>>>>>> Rcpp.
>>>>>>>>
>>>>>>>
>>>>>>> I don't think so. In the situation that Dominick is describing the C
>>>>>>> API is being used (calls to Rf_install, Rf_lang1, Rf_eval, ...) and
>>>>>>> you have to play by the rules of the C API. Essentially every time
>>>>>>> that you call a function in the C API that can cause a memory
>>>>>>> allocation you are open yourself to the possibility of having th...
2002 Jul 11
1
dyn.load tcl/tk (PR#1774)
...ls.so nls.o
ld:
Warning: Unresolved:
fabs
sqrt
R_finite
Rf_error
R_GlobalEnv
R_NamesSymbol
Rf_coerceVector
Rf_allocMatrix
Rf_allocVector
Rf_asInteger
Rf_asLogical
Rf_asReal
Rf_eval
Rf_findVar
Rf_getAttrib
Rf_install
Rf_isEnvironment
Rf_isFunction
Rf_isNewList
Rf_isNumeric
Rf_isReal
Rf_isString
Rf_lang1
Rf_lang2
Rf_protect
Rf_setAttrib
Rf_unprotect
LENGTH
R_CHAR
STRING_ELT
VECTOR_ELT
SET_VECTOR_ELT
REAL
R_registerRoutines
mkdir -p -- ../../../../library/nls/libs
gmake[5]: Leaving directory `/soft/R/R-1.5.1/src/library/nls/src'
gmake[4]: Leaving directory `/soft/R/R-1.5.1/src/library/nls/src...