Displaying 1 result from an estimated 1 matches for "others4class".
Did you mean:
otherclass
2007 Jun 04
2
locked environment and inheritance
..."myS3Pkg". Inside my package I would like to create
a S4 class which extends (adds 2 slots) another S4 class from some other package. The class
should be created in "myPkg" environment (and not global environment).
Using:
setClass("myS4class", representation("otherS4class", mydata = "numeric"),
where = topenv())
I get:
Error in assign(classMetaName(Class), def, where) :
cannot add bindings to a locked environment
I understand the fact that after "myPkg" is loaded, its namespace is sealed, but I was hoping to find a way arou...