File tree Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Expand file tree Collapse file tree 1 file changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -509,17 +509,22 @@ def reset_times(self):
509
509
rs .t_start = None
510
510
rs .sampling_frequency = self .sampling_frequency
511
511
512
- def shift_start_time (self , shift : int | float , segment_index : int | None = None ) -> None :
512
+ def shift_times (self , shift : int | float , segment_index : int | None = None ) -> None :
513
513
"""
514
- Shift the starting time of the times.
514
+ Shift all times by a scalar value. The default behaviour is to
515
+ shift all segments uniformly.
515
516
517
+ Parameters
518
+ ----------
516
519
shift : int | float
517
- The shift to apply to the first time point. If positive,
518
- the current start time will be increased by `shift`. If
519
- negative, the start time will be decreased.
520
+ The shift to apply. If positive, times will be increased by `shift`.
521
+ e.g. shifting by 1 will be like the recording started 1 second later.
522
+ If negative, the start time will be decreased i.e. as if the recording
523
+ started earlier.
520
524
521
525
segment_index : int | None
522
- The segment on which to shift the times.
526
+ The segment on which to shift the times. if `None`, all
527
+ segments will be shifted.
523
528
"""
524
529
self ._check_segment_index (segment_index )
525
530
You can’t perform that action at this time.
0 commit comments