Bioconductor / SummarizedExperiment

SummarizedExperiment container
https://bioconductor.org/packages/SummarizedExperiment
29 stars 9 forks source link

Incorrect document page #41

Closed Jiefei-Wang closed 4 years ago

Jiefei-Wang commented 4 years ago

Hi,

When typing ?SummarizedExperiment in R it brings the document of RangedSummarizedExperiment. I originally thought it was made on purpose, but from the description of RangedSummarizedExperiment,

RangedSummarizedExperiment is a subclass of SummarizedExperiment and, as such, all the methods documented in ?SummarizedExperiment also work on a RangedSummarizedExperiment object. The methods documented below are additional methods that are specific to RangedSummarizedExperiment

I think this is not intentional. There is a separate help page of SummarizedExperiment and can be accessed via ?"SummarizedExperiment-class". Perhaps ?SummarizedExperiment can be redirected to ?"SummarizedExperiment-class"?

Best, Jiefei

hpages commented 4 years ago

Thanks Jiefei.

It's on purpose because this is where the SummarizedExperiment() constructor function is documented. Depending on how this constructor is called it will return either a SummarizedExperiment or a RangedSummarizedExperiment instance. Not super clean (and maybe a cleaner situation would be to have 2 separate constructors) but the reason for this design was to preserve backward compatibility when we did the big SummarizedExperiment refactoring 8 years ago (FWIW I commented recently on this refactoring).

I just pushed a change where I replace ?SummarizedExperiment with class?SummarizedExperiment in man/RangedSummarizedExperiment-class.Rd so the command actually opens the intended page.

Jiefei-Wang commented 4 years ago

Thanks Hervé. Good to hear an interesting piece of history of Bioconductor. Since the link in the document has been fixed, I will close this issue now.