nicholasehamilton / ggtern

Extension to ggplot2 for plotting ternary diagrams
www.ggtern.com
55 stars 14 forks source link

Using ggtern in a package #23

Open gilleschapron opened 9 years ago

gilleschapron commented 9 years ago

Nicolas,

I'm do not understand an error I have when using ggtern in a function of the package I built. In my DESCRIPTION file, I'm calling ggtern in the Imports. In my function, with roxygen, I'm calling @import ggtern to. But if I only load my package, without loading ggtern in the global environnement through library(ggtern) I have the following error:

Error in UseMethod("scale_clone") : 
  no applicable method for 'scale_clone' applied to an object of class "c('tern_T', 'continuous_ternary', 'scale')"

Could you have any idea to help me about it ?

Thanks ! Gilles