R largest/smallest representable numbers
问题 I'm trying to get the largest/smallest representable number in R. After typing ".Machine" I got: $double.xmin [1] 2.225074e-308 $double.xmax [1] 1.797693e+308 However even if I type 2.225074e-309 in R command prompt I get 2.225074e-309 instead of the expected 0 How can I find the largest/smallest number for which adding or subtracting 1 would lead to either Inf(Adding 1 to largest number) or 0(subtracting 1 from smallest number) ? 回答1: .Machine$double.xmin gives the value of the smallest