Column extraction from a Time Series in Matlab

Asked

Viewed 17 times

0

I want to extract the time column of the Matlab time series, shown in the figure below. Commands to slice matrices in Matlab do not seem to work with time series. Matlab gives me the following message

y = x(:,0) Index in position 2 is invalid. Array indices must be Positive integers or Logical values.

If instead of zero I put 1 the time series is assigned integer to y, that is, both the data column and the time column, as figure.

Serie Temporal

1 answer

0

You can access her time vector through the Time property.

    y = x.Time;
  • This data comes from Simulink. I was importing through the block "TO WORKSPACE", the variable was as "time series" and changed to "time structure", so I was able to separate the two columns, but anyway, thank you.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.