[R] Extending a group of S4 classes by setClassUnion ?

Alexander juschitz_alexander at yahoo.de
Thu Mar 15 17:51:52 CET 2012


Hi Martin,
thanks for your quick answer. I didn't know that '.' could be missleading.
Is there any standard way to name function for S4 objects? "get","set"
etc..?

I saw your example, and I was wondering, why get.par(ext) put out "Son1",
and not the same as get.par(new("Son1", name="Son1", par=3))

If I define a function just like setMethod("get.par", "Father",
function(object) object at name) , for example

setMethod("get.par", "Father", function(object) object at par) 

then it would work, for all objects, which are either Son1 or Son2, but not
all object, which are "Father", contains also the variable par

 get.par(new("Father"))

Alexander



--
View this message in context: http://r.789695.n4.nabble.com/Extending-a-group-of-S4-classes-by-setClassUnion-tp4475251p4475650.html
Sent from the R help mailing list archive at Nabble.com.



More information about the R-help mailing list