transix.time#
- transix.time(duration, fs, endpoint=True)#
Generate uniformly sampled timestamps
- Parameters:
- durationfloat
The end time in seconds.
- fsint
The sampling frequency in Hertz.
- endpointbool, optional
The end time stamp to be included or not
- Returns:
- out: ndarray
time stamps
Examples
Generating timestamps for 1sec with a sampling frequency of 1kHz
>>> import transix as tx >>> tx.time(duration=1, fs=1000) [0. 0.001 0.002 ... 0.998 0.999 1. ]