Skip to content

Make duration() parse YouTube duration values #622

Closed

Description

@EricGoldsmith
> duration("11M22S")
[1] "682s (~11.37 minutes)"

is correct

> duration("PT11M22S")
[1] NA

is not.

The latter is the format used by YouTube for video duration, and is a valid notation option per the ISO 8601 spec on durations.

More info on the YT duration format: look for contentDetails.duration on this page.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions