powered by
Test if is a decimal number
is_decimal(x)
an R object
decimal is any number in the intervals (-1,0) and (0,1)
is_integer
is_decimal(0.01) # TRUE is_decimal(-0.01) # TRUE is_decimal(0) # FALSE is_decimal(1) # FALSE is_decimal(runif(5)) is_decimal(rnorm(5)) M = matrix(seq(-2, 2, length.out=10), 5, 2) is_decimal(M)
Run the code above in your browser using DataLab