globalgov / messydates

R package for Extended Date/Time Format (EDTF)
https://globalgov.github.io/messydates
Other
15 stars 1 forks source link

Rework ´contract()´ to always expand first to then display the most succinct representation #69

Closed henriquesposito closed 1 year ago

henriquesposito commented 1 year ago

Could we make it so that, if given an mdate class, contract will automatically expand first and then recontract? This would mean we can keep this new order in which contract is presented before expand and the function also makes more sense then to be user-facing.

henriquesposito commented 1 year ago

{2001-01-01, 2001-01-02, 2001-01-03} should become 2001-01-01..2001-01-03

henriquesposito commented 1 year ago

The function has been checked and updated to work accordingly.