[R] Optimization problem
ruipbarradas at sapo.pt
Thu Apr 11 12:04:06 CEST 2013
You cannot change the numerical accuracy, it's a built-in constant. To
see it use
.Machine$double.eps # smallest value different from zero
Actually, .Machine$double.eps is the "the smallest positive
floating-point number x such that 1 + x != 1"
You can try the following function
is.zero <- function(x, eps = .Machine$double.eps^0.5) abs(x) < eps
is.zero(your_value) # TRUE?
Or even try ?all.equal
Hope this helps,
Em 10-04-2013 22:13, nntx escreveu:
> Rui, thanks for your reply. You meant that it is the issue of accuracy? So if
> I change the numerical accuracy, my results can be output? Thanks a lot!
> View this message in context: http://r.789695.n4.nabble.com/Optimization-problem-tp4663821p4663928.html
> Sent from the R help mailing list archive at Nabble.com.
> R-help at r-project.org mailing list
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
More information about the R-help