Is there a standard function to generate messages like "longer
object length is not a multiple of shorter object length" but providing
more information like the names of the objects?
For example, "a/b" issues, "Warning message: In a/b : longer
object length is not a multiple of shorter object length" if the length
of one is not a multiple of the other. I want a utility to produce
messages that include the lengths of "a" and "b" and other information.
If you were to write such a function, what would you include in
it? Arguments? Values? Options?
I started creating "compareLengths.Rd" with
\usage{compareLengths(x, y, name.x=NULL, name.y=NULL, Source='',
compFun=c('length', 'NROW'), action=c(comparable='',
incomparable='warning'), maxChar=20, ...)} and \value{A character vector
of length 2. The first element is either 'equal', 'compatible' or
'incompatible'. The second element is the message composed for the
desired "action".
Thanks,
Spencer Graves
______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.