gavinsimpson / ggvegan

ggplot-based plots for vegan
https://gavinsimpson.github.io/ggvegan/
GNU General Public License v2.0
113 stars 30 forks source link

Only function avaliable is valid_layers() #25

Closed Asromer-biology closed 4 years ago

Asromer-biology commented 4 years ago

Hello there,

I have downloaded the ggvegan package using the code you provided...

library(devtools)
devtools::install_github("gavinsimpson/ggvegan", force=TRUE)

I was able to succesfully install the package however the only function that I am able to access from it is valid_layers()

When I attempt to use another function by specifying ggvegan directly... i.e. ggvegan::autoplot.cca() I recieve the following error message.

Error: 'autoplot.cca' is not an exported object from 'namespace:ggvegan'

Thank you for any assistance you may be able to offer me

gavinsimpson commented 4 years ago

This is as intended and is how S3 classes should be used/registered. As a user, you should use the autoplot() generic (or if you want to be fully qualified ggplot2::autoplot()). You should never need to call autoplot.cca(). If you do, then you need to use the ::: function as S3 methods are not exported from package namespaces.