Main Content


Read properties as single row table from TDMS-file



props = tdmsreadprop(tdmsfile) returns a table of properties from the specified TDMS-file.

props = tdmsreadprop(tdmsfile,Name=Value) uses name-value pairs to filter the information to get specific properties.


collapse all

Read the high level properties of a TDMS-file.

props = tdmsreadprop("Turbine_003.tdms")
props =

  1×7 table

        name              title         author                        description                                   datetime                datestring     timestring
    _____________    _______________    ______    ____________________________________________________    _____________________________    ____________    __________

    "Turbine_003"    "Turbine Tests"    "xyz"     "Test the Acceleration, Force and Torque of Turbine"    2021-10-18 01:57:17.000000000    "10/18/2021"    "11:27:17"

Read the properties of one channel group.

props = tdmsreadprop("Turbine_003.tdms",ChannelGroupName="Torque")
props =

  1×2 table

      name      description
    ________    ___________

    "Torque"    "CGTorque"

Narrow the scope to a single channel.

props = tdmsreadprop("Turbine_003.tdms",ChannelGroupName="Torque",ChannelName="Torque2")
props =

  1×19 table

      name        datatype     ...
    _________    ___________   ...

    "Torque2"    "DT_DOUBLE"   ...

Filter on specific properties.

props = tdmsreadprop("Turbine_003.tdms",PropertyNames=["title" "datetime" "datestring"])
props =

  1×3 table

         title                   datetime                datestring 
    _______________    _____________________________    ____________

    "Turbine Tests"    2021-10-18 01:57:17.000000000    "10/18/2021"

Input Arguments

collapse all

TDMS file name, specified as a string.

For local files, use a full or relative path that contains a file name and extension. You also can specify a file on the MATLAB path.

For Internet files, specify the URL. For example, to read a remote file from the Amazon S3 cloud:

data = tdmsread("s3://bucketname/path_to_file/data.tdms");

Example: "airlinesmall.tdms"

Data Types: char | string

Name-Value Arguments

Specify optional pairs of arguments as Name1=Value1,...,NameN=ValueN, where Name is the argument name and Value is the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

Example: ChannelGroupName="Torque",ChannelName="Torque2"

Supported name-value pairs are:

Channel group containing the channels to read from, specified as a string or character vector.

Example: "Torque"

Data Types: string | char

Name of channel to read, specified as a string or character vector. The channel must be in the channel group specified by ChannelGroupName.

Example: "Torque2"

Data Types: char | string

Property names to read, specified as a string, string array, character vector, or cell array of character vectors.

Example: ["Torque1" "Torque2"]

Data Types: char | string | cell

Output Arguments

collapse all

Properties in the TDMS-file, returned as a table.


  • TDMS functions are supported on Windows® platforms only.

Version History

Introduced in R2022a

See Also