nhejazi / biotmle

:package: :microscope: R/biotmle: Targeted Learning with Moderated Statistics for Biomarker Discovery
https://code.nimahejazi.org/biotmle/
Other
4 stars 2 forks source link

Toptable: Error: $ operator not defined for this S4 class #63

Closed dcpattie closed 5 years ago

dcpattie commented 5 years ago

Below is another error I found executing the pipeline:

head(toptable(limmaTMLEout)) Error: $ operator not defined for this S4 class

nhejazi commented 5 years ago

I was able to reproduce this problem using v1.6.0 of biotmle from Bioconductor 3.8. Please note that this is happening because of a difference between the development version of biotmle and the version of the package available from the 3.8 release of Bioconductor. To clarify, this happens because v1.6.0 of biotmle does not include the accessor function toptable (here in the development version v1.7.2 of biotmle on GitHub master) --- as such, the call to toptable above is actually calling the wrong function, namely limma::toptable (and not biotmle::toptable).

To use the native toptable accessor function from biotmle, consider installing v1.7.2 of the packages from GitHub via

remotes::install_github("nhejazi/biotmle@master")

Alternatively, note that the toptable accessor function is a convenience, and the same output may be extracted by a call that explicitly uses @ to access the appropriate slot. Thus, to extract the same information from your currently installed version of biotmle, please consider using

head(limmaTMLEout@topTable)

Please feel free to re-open this issue if this does not resolve your current problem. Hope this helps.