Skip to content
Prev 13094 / 15075 Next

Problem R-4.0 beta and Rmpfr (pre-release)

Works just fine for me on 10.15.4 and r78227. You might want to check your compiler setup against the recommended toolchain and reinstall all packages for R 4.0.

``` r
library(gmp)
#>
#> Attaching package: 'gmp'
#> The following objects are masked from 'package:base':
#>
#> %*%, apply, crossprod, matrix, tcrossprod
library(Rmpfr)
#> C code of R package 'Rmpfr': GMP using 64 bits per limb
#>
#> Attaching package: 'Rmpfr'
#> The following object is masked from 'package:gmp':
#>
#> outer
#> The following objects are masked from 'package:stats':
#>
#> dbinom, dgamma, dnorm, dpois, pnorm
#> The following objects are masked from 'package:base':
#>
#> cbind, pmax, pmin, rbind

x <- 1400+ 0:10
print(dpois(x, 1000), digits =18)
#> [1] 1.46677334419659338e-33 1.04694742626454156e-33 7.46752800474106016e-34
#> [4] 5.32254312525935864e-34 3.79098513195210765e-34 2.69821005832831136e-34
#> [7] 1.91906832029070091e-34 1.36394336907638670e-34 9.68709779173582432e-35
#> [10] 6.87515812046484244e-35 4.87599866699657026e-35
dpois(mpfr(x, 120), 1000)##
#> 11 'mpfr' numbers of precision 120 bits
#> [1] 1.4667733441965683030895281895730571526e-33
#> [2] 1.0469474262645027145535533116153155973e-33
#> [3] 7.4675280047396769939625771156584564775e-34
#> [4] 5.3225431252599265815841604530708884358e-34
#> [5] 3.7909851319515146592479775306772709641e-34
#> [6] 2.698210058328480184518133473791651932e-34
#> [7] 1.9190683202905264470256994834933513035e-34
#> [8] 1.3639433690764224925555788795261914005e-34
#> [9] 9.6870977917359552028095090875439730376e-35
#> [10] 6.8751581204655466308087360450986323895e-35
#> [11] 4.8759986669968415821338553511337818329e-35
```

<sup>Created on 2020-04-16 by the [reprex package](https://reprex.tidyverse.org) (v0.3.0)</sup>
On 16. Apr 2020, 08:56 +0200, Berend Hasselman <bhh at xs4all.nl>, wrote: