6 ms·
> Beyond functions there is nothing good. There are three object-oriented programming systems, none of which are simple or straightforward. I don't think this
by vsbuffalo 12y ago
> Beyond functions there is nothing good. There are three object-oriented programming systems, none of which are simple or straightforward.
I don't think this is quite fair. R was greatly inspired from Scheme and stole a lot of good ideas. S4 is very similar to CLOS, and does a fairly good job. If you come from Python or Java, this system looks crazy, but being unfamiliar with a language style does not make the language bad.
> To this day I don't have a good mental picture of genomicRange (a foundational bioinformatics package in Bioconductor for NGS data analysis) data structure and how to manipulate it (one main data structure, I believe).
It's a dataframe attached to ranges. This design extends lower classes like IRanges, and all the accessors, setters, etc are consistent. You can manipulate the range part with integer range operations and manipulate the dataframe part as a dataframe. I would check out the IRanges vignette — this is very helpful.
> R, more than any other language I know, is an implementation-defined language.
This is the most severe problem for sure. I'm cross my fingers someone forks R's implementation and does it right (which should break a lot of packages and code).
- jghn 12y agoS4 was heavily influenced by Dylan, FWIW
- east2west 12y ago>It's a dataframe attached to ranges. This design extends lower classes like IRanges, and all the accessors, setters, etc are consistent. You can manipulate the range part with integer range operations and manipulate the dataframe part as a dataframe. I would check out the IRanges vignette — this is very helpful. I agree that the accessors, setters of GRange are consistent. I was having trouble picturing how manipulating the range part impacts the dataframe. I think they are like a database table joint but that is not explicitly spelled out. It becomes even less clear what happens to the attached dataframes when merging two GRange intervals. I once had to a symmetric difference of two GRange and it took a few hours of staring at the manual and trying out things at the command prompt.