Related to "Date/Time"
date package
The date
package provides date and time constants and functions.
boundaries package
The boundaries
package provides operators for finding the boundaries around certain days, months, and weeks.
date.add() function
date.add()
adds a duration to a time value and returns the resulting time value.
date.hour() function
date.hour()
returns the hour of a specified time. Results range from [0 - 23]
.
date.microsecond() function
date.microsecond()
returns the microseconds for a specified time. Results range from [0-999999]
.
date.millisecond() function
date.millisecond()
returns the milliseconds for a specified time. Results range from [0-999]
.
date.minute() function
date.minute()
returns the minute of a specified time. Results range from [0 - 59]
.
date.month() function
date.month()
returns the month of a specified time. Results range from [1 - 12]
.
date.monthDay() function
date.monthDay()
returns the day of the month for a specified time. Results range from [1 - 31]
.
date.nanosecond() function
date.nanosecond()
returns the nanoseconds for a specified time. Results range from [0-999999999]
.
date.quarter() function
date.quarter()
returns the quarter for a specified time. Results range from [1-4]
.
date.scale() function
date.scale()
will multiply the duration by the given value.
date.second() function
date.second()
returns the second of a specified time. Results range from [0 - 59]
.
date.sub() function
date.sub()
subtracts a duration from a time value and returns the resulting time value.
date.time() function
date.time()
returns the time value of a specified relative duration or time.
date.truncate() function
date.truncate()
returns a time truncated to the specified duration unit.
date.week() function
date.week()
returns the ISO week of the year for a specified time. Results range from [1 - 53]
.
date.weekDay() function
date.weekDay()
returns the day of the week for a specified time. Results range from [0 - 6]
.
date.year() function
date.year()
returns the year of a specified time.
date.yearDay() function
date.yearDay()
returns the day of the year for a specified time. Results can include leap days and range from [1 - 366]
.
experimental.addDuration() function
experimental.addDuration()
adds a duration to a time value and returns the resulting time value.
experimental.alignTime() function
experimental.alignTime()
shifts time values in input tables to all start at a common start time.
experimental.subDuration() function
experimental.subDuration()
subtracts a duration from a time value and returns the resulting time value.
experimental.window() function
experimental.window()
groups records based on time.
hourSelection() function
hourSelection()
filters rows by time values in a specified hour range.
now() function
now()
is a function option that, by default, returns the current system time.
system.time() function
system.time()
returns the current system time.
timeShift() function
timeShift()
adds a fixed duration to time columns.
timezone.fixed() function
timezone.fixed()
returns a location record with a fixed offset.
timezone.location() function
timezone.location()
returns a location record based on a location or timezone name.
today() function
today()
returns the now() timestamp truncated to the day unit.
truncateTimeColumn() function
truncateTimeColumn()
truncates all input time values in the _time
to a specified unit.
boundaries.friday() function
boundaries.friday()
returns a record with start
and stop
boundary timestamps for last Friday.
boundaries.monday() function
boundaries.monday()
returns a record with start
and stop
boundary timestamps of last Monday. Last Monday is relative to now()
. If today is Monday, the function returns boundaries for the previous Monday.
boundaries.month() function
boundaries.month()
returns a record with start
and stop
boundary timestamps for the current month.
boundaries.saturday() function
boundaries.saturday()
returns a record with start
and stop
boundary timestamps for last Saturday.
boundaries.sunday() function
boundaries.sunday()
returns a record with start
and stop
boundary timestamps for last Sunday.
boundaries.thursday() function
boundaries.thursday()
returns a record with start
and stop
boundary timestamps for last Thursday.
boundaries.tuesday() function
boundaries.tuesday()
returns a record with start
and stop
boundary timestamps of last Tuesday.
boundaries.wednesday() function
boundaries.wednesday()
returns a record with start
and stop
boundary timestamps for last Wednesday.
boundaries.week() function
boundaries.week()
returns a record with start
and stop
boundary timestamps of the current week. By default, weeks start on Monday.
boundaries.yesterday() function
boundaries.yesterday()
returns a record with start
and stop
boundary timestamps for yesterday.
Work with time types
A time type represents a single point in time with nanosecond precision. Learn how to work with time data types in Flux.
boundaries.friday() function
boundaries.friday()
returns a record with start
and stop
boundary timestamps for last Friday.
boundaries.monday() function
boundaries.monday()
returns a record with start
and stop
boundary timestamps of last Monday. Last Monday is relative to now()
. If today is Monday, the function returns boundaries for the previous Monday.
boundaries.month() function
boundaries.month()
returns a record with start
and stop
boundary timestamps for the current month.
boundaries.saturday() function
boundaries.saturday()
returns a record with start
and stop
boundary timestamps for last Saturday.
boundaries.sunday() function
boundaries.sunday()
returns a record with start
and stop
boundary timestamps for last Sunday.
boundaries.thursday() function
boundaries.thursday()
returns a record with start
and stop
boundary timestamps for last Thursday.
boundaries.tuesday() function
boundaries.tuesday()
returns a record with start
and stop
boundary timestamps of last Tuesday.
boundaries.wednesday() function
boundaries.wednesday()
returns a record with start
and stop
boundary timestamps for last Wednesday.
boundaries.week() function
boundaries.week()
returns a record with start
and stop
boundary timestamps of the current week. By default, weeks start on Monday.
boundaries.yesterday() function
boundaries.yesterday()
returns a record with start
and stop
boundary timestamps for yesterday.