fixing ordinal dates, lots of error checking and tests on ISO8601