[R] using initialize or using a constructor function
Martin Morgan
mtmorgan at fhcrc.org
Mon Mar 14 16:58:03 CET 2011
On 03/13/2011 09:01 PM, Laura Smith wrote:
> Hi
>
> I'm trying to learn about S4 methods, classes, etc.
>
> Is it better to use initialize or use a construction function, please?
Hi Laura -- partly a matter of taste; 'initialize' actually establishes
quite a complicated contract, and I find it easier (though maybe
short-sighted) to write constructors. Martin
>
> Thank you.
>
> Laura Smith
>
> [[alternative HTML version deleted]]
>
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
--
Computational Biology
Fred Hutchinson Cancer Research Center
1100 Fairview Ave. N. PO Box 19024 Seattle, WA 98109
Location: M1-B861
Telephone: 206 667-2793
More information about the R-help
mailing list