[R] Rmpfr into data.frame

Troels Ring tring at gvdnet.dk
Mon Nov 7 10:09:02 CET 2016


Dear friends - Windows, R version 3.2.1

I wanted to make a ggplot2 using Rmpfr high precision data - but cannot 
make the data into a data.frame, as wanted by ggplot2. Hence

library(Rmpfr)
a <- mpfr(1,120)
b <- mpfr(2,120)
dff <- data.frame(a=a,b=b)

elicits errors

Error in as.data.frame.default(x[[i]], optional = TRUE) :
   cannot force class »structure("mpfr1", package = "Rmpfr")« into 
data.frame

(my translation of Danish error)

How can I do it best?



More information about the R-help mailing list