gettimeseriesnames

Names of the time series inside a tscollection.

Category: Language Fundamentals > Data Types

Syntax

names = gettimeseriesnames(tsc)

Returns the member names as a cell array.

Description

A tscollection groups time series that share one time vector. Each member is reachable by its Name, and gettimeseriesnames lists those names, in the order the members were added.

Input arguments

tsc
tscollection object.

Output arguments

names
Cell array of character vectors, one per member timeseries.

Example

Members of a collection

tc = tscollection(timeseries([1; 2; 3], [0; 1; 2], 'Name', 'pos'));
tc = addts(tc, timeseries([5; 6; 7], [0; 1; 2], 'Name', 'vel'));
gettimeseriesnames(tc)
Output
ans = 1×2 cell

    {'pos'}    {'vel'}

See also

tscollection addts removets timeseries settimeseriesnames