datetime variables from a timerange

I have a timerange variable with a start time and end time. Is there a way extract those datetime values from a timerange variable?

2 Commenti

Do you mean a timeseries object? You can use linspace between start and end time based on number of elements
Walter, timerange is a datatype used to index timetables (and maybe do other things).
i have not had luck with this either. if i recall correctly, you can't "char" a timerange right? but since presumably you create your timerange variable from 2 datetimes, just save those as their own variables first?

Accedi per commentare.

 Risposta accettata

Walter Roberson
Walter Roberson il 22 Ott 2020

0 voti

There are no public properties or methods to examine that information. However you can struct() the object and examine the fields "first" and "last"

Più risposte (0)

Categorie

Scopri di più su Simulink in Centro assistenza e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by