duration

Methods

Method Reference: duration.hours

duration: X = hours (D)

Duration equivalent numeric values in hours.

X = hours (D) converts durations in D to the equivalent number of hours. X is a double array of the same size as D.

Source Code: duration

Example: 1

As a duration method, hours returns the duration expressed as a number of hours — the inverse of the hours builder. A single duration can be read out in any unit this way.

 d = hours (30) + minutes (15)
d =
  duration

   30.25 hr
 hours (d)
ans = 30.250