0.60

ReferenceRangesRead and write range data

Read and write range data

Read and write the data of a range without exact timestamps.

A range knows its start and end time, so you can read and write its data without typing timestamps.

Read from a range

Enterprise

In the ranges toolbar, right-click a range and select Add to new plot. The Console opens a line plot of the range with no channels. Open the component toolbar and select channels in Y1.

To add the range to a line plot that is already open, focus the plot, then select Add to active plot. See line plots.

Write to a range

A write to a range starts at the start time of the range. Include the index channel of the data with timestamps inside the range.

Enterprise
import synnax as sy

my_range = client.ranges.retrieve(name="My Interesting Test")
start = my_range.time_range.start
my_range.write(
    {
        "my_time": [start + sy.TimeSpan.SECOND * i for i in range(3)],
        "my_precise_tc": [301.2, 301.5, 301.9],
    }
)