Learn R Programming

matlab (version 0.7-6)

ceil: MATLAB ceil function

Description

Rounds to the nearest integer.

Usage

ceil(x)

Arguments

x
numeric to be rounded

Value

  • Returns vector containing smallest integers not less than the corresponding elements of argument x.

Details

Simply invokes base::ceiling for those more used to C library API name.

Examples

Run this code
ceil(c(0.9, 1.3, 2.4))

Run the code above in your browser using DataLab