split_unit | R Documentation |
Splits a unit string (e.g., "2 weeks") into the amount (2) and unit ("weeks")
split_unit(unit_string)
unit_string |
the string to split |
a list with two elements, "num" (the amount) and "unit", , for use with lubridate::period
Sebastian Funk
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.