[R] warning creating an as.array method in a package
friendly at yorku.ca
Thu Dec 2 15:07:21 CET 2010
On 12/2/2010 8:58 AM, Michael Friendly wrote:
> Under ?methods the Note says
> Functions can have both S3 and S4 methods, and function showMethods will
> list the S4 methods (possibly none).
> Does the warning mean that I cannot (or should not) have an S3 as.array
> method in a package?
> The method works in my context, but the warning will create problems
> when I submit to CRAN, so I would rather avoid it.
A little more testing: Same warning when I load my package, whether or
not Matrix has been loaded:
Loading required package: vcd
Loading required package: MASS
Loading required package: grid
Loading required package: colorspace
Loading required package: gnm
found an S4 version of ‘as.array’ so it has not been imported correctly
Function: as.array (package base)
But as.array does show up as a method for my class:
 as.array.loddsratio* as.data.frame.loddsratio*
 as.matrix.loddsratio* coef.loddsratio*
 confint.loddsratio* dim.loddsratio*
 dimnames.loddsratio* print.loddsratio*
Non-visible functions are asterisked
Michael Friendly Email: friendly AT yorku DOT ca
Professor, Psychology Dept.
York University Voice: 416 736-5115 x66249 Fax: 416 736-5814
4700 Keele Street Web: http://www.datavis.ca
Toronto, ONT M3J 1P3 CANADA
More information about the R-help