KxSystems / rkdb

R client for kdb+
https://code.kx.com/q/interfaces
Apache License 2.0
41 stars 29 forks source link

Consider using tidyverse/hms for time type #34

Open sv opened 6 years ago

sv commented 6 years ago

https://hms.tidyverse.org/index.html

statquant commented 5 years ago

What does that bring over difftime ? What precision do we need ?

sv commented 5 years ago

We need up to millisecond for time. integer is enough for this. In current master it converts just to vector of ints. In my branch I have it as POSIXct: which is has date in it and timezone.
difftime has unit only up to seconds, which is not suitable. hms is based on difftime and can go up to microseconds according to description and can play with posixct, be nagative or more then 24hrs

statquant commented 3 years ago

Is this still open? The nanotime package has a nanoduration class which would be better suited I think. It handles nanoseconds and is using integer64 under the hood