[Rd] Why doesn't R have a float data type?
cdetermanjr at gmail.com
Tue Jun 30 19:32:01 CEST 2015
Hi Greg, I was referring to the single precision type. Your points were
what I expected. I just wanted to ask the R community if there was any
other reason than 'there wasn't any reason to implement it'.
On Tue, Jun 30, 2015 at 12:29 PM, Greg Snow <538280 at gmail.com> wrote:
> My understanding is that R does have a float type, it is just called
> "double" instead of "float".
> If you are referring to a single precision floating point type, then R
> does have the "as.single" function, but that does not really change
> the way the number is stored, just sets a flag so that the proper
> conversion is done when passing to the ".C" or ".fortran" functions.
> The original S language and S+ would store things in single precision
> if needed, but for computations these values were almost always
> converted to doubles for precision. By the time R was developed the
> memory saving of using single precision instead of double precision
> was not as big an issue, so I expect that nobody ever considered it
> worth the effort to fully implement the single precision storage.
> If you mean something else other than the above by "float data type"
> then please give us more details so that we can better answer the
> On Tue, Jun 30, 2015 at 10:42 AM, Charles Determan
> <cdetermanjr at gmail.com> wrote:
> > This is strictly a curiosity question. I am aware the R doesn't possess
> > float data type. I also don't mean to request that such functionality be
> > implemented as I'm sure it would require a large amount of work with
> > potential back compatibility conflicts. But I wanted to know why R has
> > never had a float data type available?
> > Regards,
> > Charles
> > [[alternative HTML version deleted]]
> > ______________________________________________
> > R-devel at r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-devel
> Gregory (Greg) L. Snow Ph.D.
> 538280 at gmail.com
[[alternative HTML version deleted]]
More information about the R-devel