gettsbetweenevents
Create timeseries
between events
Syntax
Description
tsout = gettsbetweenevents(
returns a tsin
,tsevent1
,tsevent2
)timeseries
object with samples occurring between the
events tsevent1
and tsevent2
in the input
timeseries
tsin
. The arguments tsevent1
and
tsevent2
can be either tsdata.event
objects or character vectors containing the names of the events. When
tsevent1
and tsevent2
are
tsdata.event
objects, the times defined by the events specify
the time. When tsevent1
and tsevent2
are
character vectors, the first tsdata.event
object in the
Events
property of tsin
that matches the
event names specifies the time.
Examples
Input Arguments
Tips
When the input
timeseries
objecttsin
contains date character vectors andtsevent1
andtsevent2
use numeric time, the time selected is treated as a date that is calculated relative to theStartDate
property intsin.TimeInfo
.When
tsin
uses numeric time andtsevent1
andtsevent2
use calendar dates, the time selected is treated as a numeric value that is not associated with a calendar date.
Version History
Introduced before R2006a
See Also
gettsafterevent
| gettsbeforeevent
| timeseries
| tsdata.event