Displaying 2 results from an estimated 2 matches for "67f5e0".
Did you mean:
6750
2010 Nov 12
1
SEXPs and slots
Hello,
I've created this class:
setClass("example",
representation (
size = "numeric",
id = "character"
)
)
Suppose I create a new instance of this class:
> x <- new("example", 4, "id_value")
This creates an S4 object with two slots. Am I correct in thinking that
slots are "filled" by SEXPs?
2010 Nov 15
1
SEXP and slots
...96ed08 09 CHARSXP g1c1 [MARK,gp=0x21] "example"
>> ATTRIB:
>> @df70fd0 02 LISTSXP g0c0 []
>> TAG: @624f70 01 SYMSXP g1c0 [MARK,NAM(2)] "package"
>> @c0f6d88 16 STRSXP g0c1 [NAM(2)] (len=1, tl=0)
>> @67f5e0 09 CHARSXP g1c2 [MARK,gp=0x21,ATT] ".GlobalEnv"
>>
>> that the 'eg' object is an S4SXP with an attribute that is a LISTSXP.
>> The LISTSXP has elements that are tagged with SYMSXP representing the
>> slot name, and values that are REALSXP (for &...