Full_Name: Ben Hansen
Version: 2.6.1
OS: Windows
Submission from: (NULL) (66.93.3.101)
Hi,
In R 2.6.0 or 2.6.1 on Windows, I get the following upon opening the GUI (no
previous commands or special settings):
> signif(digits=4, x=1/3)
[1] 4
It seems to be taking 4 to be the "x" argument, the nu
NO
Dear Ben,
If you take a look at the definition of signif() in R 2.6.1 and, e.g.,
in R 2.5.1 you'll see the source of the problem:
R 2.6.1:
> signif
function (x, digits = 6) .Primitive("signif")
R 2.5.1:
> signif
function (x, digits = 6)
.Internal(signif(x, digits))
>From ?Primitive:
"
You could always define your own signif() as
signif <- function(x, digits = 6){
base::signif(x, digits)
}
I do something like this for signif() and round() because economists don't
like the round-to-even convention R uses. My round() function, for example,
is:
round <- function(x, digits = 0