Skip to Main Content Skip to Search
Product Documentation

transpose - Class: timeseries

Transpose timeseries object

Syntax

ts1 = transpose(ts)

Description

ts1 = transpose(ts) returns a new timeseries object, ts1, with IsTimeFirst value set to the opposite of what it is for ts. For example, if ts has the first data dimension aligned with the time vector, ts1 has the last data dimension aligned with the time vector.

Tips

Input Arguments

ts

The timeseries object that you want to transpose.

Output Arguments

ts1

The timeseries object that is the result of transposing the original timeseries object.

Examples

Suppose that a timeseries object, ts, has ts.Data size 10-by-3-by-2 and its time vector has a length of 10. The IsTimeFirst property of ts is true, which means that the first dimension of the data aligns with the time vector. transpose(ts) modifies the timeseries object, such that the last dimension of the data now aligns with the time vector. This permutes the data, such that the size of ts.Data becomes 3-by-2-by-10.

See Also

timeseries | transpose

  


Free MATLAB Interactive Kit

Explore how to use MATLAB to make advancements in engineering and science.


Download free kit

Trials Available

Try the latest version of MATLAB and other MathWorks products.


Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS