R: Pretty formatting of seconds

pretty_sec {prettyunits} | R Documentation

## Pretty formatting of seconds

### Description

Pretty formatting of seconds

### Usage

    pretty_sec(sec, compact = FALSE)

### Arguments

`sec` | Numeric vector of seconds.
`compact` | If true, then only the first non-zero unit is used. See examples below.

### Value

Character vector of formatted time intervals.

### See Also

Other time: `pretty_dt`; `pretty_ms`

### Examples

    pretty_sec(c(1337, 13370, 133700, 1337000, 13370000))

    pretty_sec(c(1337, 13370, 133700, 1337000, 13370000),
               compact = TRUE)

[Package prettyunits version 1.0.2 Index]