RegularlySampledQ[tes]
gives True if tes is a regular time or event series data, and False otherwise.
RegularlySampledQ
RegularlySampledQ[tes]
gives True if tes is a regular time or event series data, and False otherwise.
Details
- RegularlySampledQ is typically used to check whether a time or event series has uniformly spaced timestamps.
- A time series is regular if the sampling increment is some constant
. -
- Possible forms of time or event series data tes include:
-
TimeSeries[…] continuous time-ordered sampled data EventSeries[…] collection of temporal events with values TemporalData[…] one or more paths composed of time-value pairs {{t1,x1},{t2,x2},…} list of time-value pairs {x1,x2,…} list of values with implied integer times starting at 0 - For a TemporalData object with multiple paths, RegularlySampledQ returns True if all paths in the ensemble are regular.
Examples
open all close allBasic Examples (3)
Check whether a time series is uniformly spaced:
TimeSeries[Range[4], {Today + Quantity[{1, 3, 7, 8}, "Days"]}]RegularlySampledQ[%]A time series with timestamps given in the iterator form is regular:
TimeSeries[Range[10], {Automatic, Today, "BusinessDay"}]RegularlySampledQ[%]Check if a multipath TemporalData object is regularly sampled:
RandomFunction[PoissonProcess[3], {1, 100}, 3]RegularlySampledQ[%]RandomFunction[WienerProcess[], {0, 1, .1}, 3]RegularlySampledQ[%]Scope (5)
Vector data is always regular:
RegularlySampledQ[{Subscript[x, 1], Subscript[x, 2], Subscript[x, 3], Subscript[x, 4], Subscript[x, 5]}]Test the regularity of time-value pairs:
RegularlySampledQ[{{1, Subscript[``v``, 1]}, {2, Subscript[``v``, 2]}, {3, Subscript[``v``, 3]}}]RegularlySampledQ[{{1, Subscript[``v``, 1]}, {2.5, Subscript[``v``, 2]}, {3, Subscript[``v``, 3]}}]Determine whether a TimeSeries is regularly spaced:
TimeSeries[Range[5], {Array[Prime, 5]}]RegularlySampledQ[%]Determine whether an EventSeries is regularly spaced:
EventSeries[1, {DayRange[DateObject[{2026}, "Year"], DateObject[{2027}, "Year"], "Holiday"]}]RegularlySampledQ[%]Test an ensemble of paths for regularity:
TemporalData[{{1, 2, 3}, {11, 22, 33, 44}}, {{{0.1, 0.2, 0.3}}, {Range[4]}}]RegularlySampledQ[%]TemporalData[{{1, 2, 3}, {11, 22, 33, 44}}, {{{0.1, 0.2, 0.5}}, {Range[4]}}]RegularlySampledQ[%]Properties & Relations (4)
A time series is regular if every time step is equal to the MinimumTimeIncrement:
data = RandomFunction[ARMAProcess[{.1}, {.2}, 1], {1, 10}]Differences[data["Times"]]MinimumTimeIncrement[data]RegularlySampledQ[data]In an irregular series, the differences of the timestamps will be different:
RandomFunction[PoissonProcess[4], {1, 2}]Differences[%["Times"]]RegularlySampledQ[%%]A time series can be made regular using TimeSeriesResample:
data = TimeSeries[{6, 8, 10, 11, 12, 12}, {{1., 1.14, 1.22, 1.45, 1.75, 2.}}]RegularlySampledQ[data]TimeSeriesResample[data]RegularlySampledQ[%]Coerce a time series to be treated as regular using the TemporalRegularity option:
ts = TimeSeries[{1, 2, 3, 4}, {{1, 2, 2.5, 4}}]RegularlySampledQ[ts]TimeSeries[{1, 2, 3, 4}, {{1, 2, 2.5, 4}}, TemporalRegularity -> True]RegularlySampledQ[%]Possible Issues (2)
A time series may be regular in a given day type but irregular in another:
data = TimeSeries[Range[10], {Automatic, Today, "BusinessDay"}]RegularlySampledQ[data]The path does not follow business day steps:
path = data["Path"]RegularlySampledQ[path]The path follows standard days, while the original time series follows "BusinessDay":
MinimumTimeIncrement /@ {path, data}The TemporalRegularity option does not change the timestamps but overrides the regularity of the series:
data = TimeSeries[{1, 2, 3, 4}, {{1, 2, 2.5, 4}}, TemporalRegularity -> True]data["Timestamps"]//NormalRegularlySampledQ[data]Related Guides
History
Text
Wolfram Research (2014), RegularlySampledQ, Wolfram Language function, https://reference.wolfram.com/language/ref/RegularlySampledQ.html.
CMS
Wolfram Language. 2014. "RegularlySampledQ." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/RegularlySampledQ.html.
APA
Wolfram Language. (2014). RegularlySampledQ. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/RegularlySampledQ.html
BibTeX
@misc{reference.wolfram_2026_regularlysampledq, author="Wolfram Research", title="{RegularlySampledQ}", year="2014", howpublished="\url{https://reference.wolfram.com/language/ref/RegularlySampledQ.html}", note=[Accessed: 12-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_regularlysampledq, organization={Wolfram Research}, title={RegularlySampledQ}, year={2014}, url={https://reference.wolfram.com/language/ref/RegularlySampledQ.html}, note=[Accessed: 12-June-2026]}