8.2.14 duration

Class: duration

Represents durations or periods of time as an amount of fixed-length time (i.e. fixed-length seconds). It does not care about calendar things like months and days that vary in length over time.

This is an attempt to reproduce the functionality of Matlab’s duration. It also contains some Octave-specific extensions.

Duration values are stored as double numbers of days, so they are an approximate type. In display functions, by default, they are displayed with millisecond precision, but their actual precision is closer to nanoseconds for typical times.

Instance Variable of duration: double days

The underlying datenums that represent the durations, as number of (whole and fractional) days. These are uniform 24-hour days, not calendar days.

This is a planar property: the size of days is the same size as the containing duration array object.

Instance Variable of duration: char Format

The format to display this duration in. Currently unsupported.