search for: domultiply

Displaying 2 results from an estimated 2 matches for "domultiply".

2011 Aug 23
1
R.oo modify an object inside another classes method
Can someone show me how to modify one (R.oo) class's object inside another (R.oo) class's method? Is that possible with the R.oo package? A quick example or reference to an example would be outstanding... Thanks, Ben [[alternative HTML version deleted]]
2011 Aug 26
0
R.oo inheritance with pass by reference
...S3("getPerObj", "AgeMultiplier", function(this, ...) { this$.perobj }) setMethodS3("getAM", "AgeMultiplier", function(this, ...) { this$.AM }) setMethodS3("getWM", "AgeMultiplier", function(this, ...) { this$.WM }) setMethodS3("doMultiplyAge", "AgeMultiplier", function(this, ...) { a = this$.perobj; this$.AM = a$getAge() * this$.m; a$setAge(this$.AM); }) setMethodS3("doMultiplyWeight", "AgeMultiplier", function(this, ...) { a = this$.perobj; this$.WM = a$getWeight() * this$.m; a$se...