I've got a weird problem with R. I'm trying this:
is.wholenumber(5)
and I get
Error: could not find function "is.wholenumber"
I don't understand what the problem is. It's a basic function which is even referred to in: help(is.integer) so it should be there without needing additional downloading or special way of using?!?
library("FRACTION")
is.wholenumber(5)
[1] TRUE
is.wholenumber() is not a base function, but rather one defined in the example as so:
is.wholenumber <- function(x, tol = .Machine$double.eps^0.5) {
abs(x - round(x)) < tol
}
You can type that in and then it will be a function.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With