Closed walaj closed 8 years ago
This is an issue I've wrestled with before - it's a result of overloading S3 methods in an S4 object. Plot is an S3 method, and essentially R is not recognizing the gTrack version.
Ive been able to get rid of it before, but just through trial and error, and not my figuring out what was going on.
Might be NAMESPACE problem
have we figured this out yet?
Yeah, it seems to work now. I really don't understand this still... I think adding this helped??
Anyone know the right way to do this? It looks like the method is being exported in the NAMESPACE file, and it shows up as accepting a gTrack with a showMethods('plot') call, but its not detecting gTrack when I build gTrack as a package rather than source (If I source gTrack.R directly, plot(g) works). If I attach as package, it errors with this when trying to call base::plot:
Error in as.double(y) : cannot coerce type 'S4' to vector of type 'double'
Any thoughts?