Displaying 7 results from an estimated 7 matches for "r_data_class".
2013 Apr 26
1
RFC: R_data_class as part of the C-API
Hi,
In src/attrib.c, the comment for the function R_data_class is:
```
/* the S4-style class: for dispatch required to be a single string;
for the new class() function;
if(!singleString) , keeps S3-style multiple classes.
Called from the methods package, so exposed.
*/
SEXP R_data_class(SEXP obj, Rboolean singleString)
```
I am obviously writin...
2007 Oct 07
1
R 2.6.0 S4 data breakage, R _data_class(), class<-, etc.
...; does not set the S4 object bit. I suppose the correct way
would be to do new(...)? This needs to be written down somewhere...
The asymmetry is somewhat surprising though.
3) We have some C code which branches depending on the S4 class.
The R extension doc didn't explain that one needs to do R_data_class()
rather than classgets() (or 'getAttrib(x, RClassSymbol)') to retrieve
S4 classes; further more,
R_data_class() is not part of the public API, and I only found it by
looking at the C code of 'class()' (do_class()). But R_data_class()
is part of exposed binary interface and the meth...
2007 Apr 10
1
list/matrix chimera
...a matrix, but returns lists for subset operations.
This was brought to my attention by a user that encountered such an
object and was quite confused by its behavior. Although I have not
found the code that created the object yet, I believe that code is
simply incorrect. Nevertheless, I wonder if R_data_class in attrib.c
should be a bit more discriminating and only return matrix or array
for atomic vectors. Perhaps something like this:
--- a/src/main/attrib.c
+++ b/src/main/attrib.c
@@ -536,7 +536,7 @@ SEXP R_data_class(SEXP obj, Rboolean singleString)
if(n == 0) {
SEXP dim = getAttrib(ob...
2005 Jul 20
1
(PR#8017) build of REventLoop package crashes with 2.1 due
...a UTF-8 locale? */
> 596a594
>> # define duplicated Rf_duplicated
> 633c631
> < # define Mbrtowc Rf_mbrtowc
> ---
>> # define match Rf_match
> 686a685
>> int R_ShowFile(char*, char*);
> 799,800c798
> < SEXP R_data_class(SEXP , Rboolean);
> < SEXP R_data_class2(SEXP);
> ---
>> SEXP R_data_class(SEXP , int);
> 864,869d861
> < typedef enum {
> < Rprt_adj_left = 0,
> < Rprt_adj_right = 1,
> < Rprt_adj_centre = 2
> < } Rprt_adj;
> <
> 872,939c864
>...
2005 Jul 19
0
build of REventLoop package crashes with 2.1 due tosyntax error in Defn.h (PR#8017)
...boolean utf8locale INI_as(FALSE); /* is this a UTF-8 locale? */
596a594
> # define duplicated Rf_duplicated
633c631
< # define Mbrtowc Rf_mbrtowc
---
> # define match Rf_match
686a685
> int R_ShowFile(char*, char*);
799,800c798
< SEXP R_data_class(SEXP , Rboolean);
< SEXP R_data_class2(SEXP);
---
> SEXP R_data_class(SEXP , int);
864,869d861
< typedef enum {
< Rprt_adj_left = 0,
< Rprt_adj_right = 1,
< Rprt_adj_centre = 2
< } Rprt_adj;
<
872,939c864
< char *EncodeString(SEXP, int, int, Rprt_adj);
<
&l...
2002 Jan 02
1
Building R-1.4 on Tru64
...ue
Rf_NewEnvironment
R_set_standardGeneric_ptr
R_GlobalEnv
R_set_quick_method_check
Rf_install
Rf_allocVector
LOGICAL
R_PreserveObject
Rf_mkChar
SET_STRING_ELT
Rf_findVar
R_UnboundValue
VECTOR_ELT
R_NamesSymbol
Rf_getAttrib
Rf_length
STRING_ELT
R_CHAR
R_do_slot
Rf_asChar
PRINTNAME
Rf_isNull
CAR
CDR
R_data_class
Rf_isFunction
Rf_findFun
SETCAR
Rf_eval
INTEGER
CLOENV
Rf_findVarInFrame
Rf_isSymbol
ENCLOS
SYMVALUE
Rf_asLogical
R_MissingArg
Rf_isPrimitive
do_set_prim_method
BODY
R_deferred_default_method
PREXPR
PRENV
R_DotsSymbol
DDVAL
R_set_prim_method
Rf_defineVar
R_do_slot_assign
mkdir ../../../../library/m...
2002 Jul 11
1
dyn.load tcl/tk (PR#1774)
...Rf_isEnvironment
Rf_isFunction
Rf_isNull
Rf_isObject
Rf_isPrimitive
Rf_isSymbol
Rf_length
Rf_mkChar
ATTRIB
R_CHAR
STRING_ELT
SET_STRING_ELT
VECTOR_ELT
LOGICAL
INTEGER
TAG
CAR
CDR
MISSING
SETCAR
BODY
CLOENV
PRINTNAME
SYMVALUE
DDVAL
FRAME
ENCLOS
Rf_type2str
R_PreserveObject
R_set_standardGeneric_ptr
R_data_class
R_deferred_default_method
R_set_prim_method
do_set_prim_method
R_set_quick_method_check
R_do_slot
R_do_slot_assign
mkdir -p -- ../../../../library/methods/libs
gmake[5]: Leaving directory `/soft/R/R-1.5.1/src/library/methods/src'
gmake[4]: Leaving directory `/soft/R/R-1.5.1/src/library/methods/...