Setting 'float' as storage mode of a single precision object

后端 未结 1 490
逝去的感伤
逝去的感伤 2021-01-23 23:48

I wish to display the precision of an object as \'float\' in R while having single precision. Currently its stored as default type \'double\'.

timevector=c(1.5,         


        
1条回答
  •  感动是毒
    2021-01-24 00:08

    From the documentation:

    R has no single precision data type. All real numbers are stored in double precision format. The functions as.single and single are identical to as.double and double except they set the attribute Csingle that is used in the .C and .Fortran interface, and they are intended only to be used in that context.

    http://stat.ethz.ch/R-manual/R-devel/library/base/html/double.html

    0 讨论(0)
提交回复
热议问题