主要内容

Simulink.sdi.Parquet.getSignalMetadata

R2026b

Get signal metadata from Parquet file

Since R2026b

    Description

    metadataTable = Simulink.sdi.Parquet.getSignalMetadata(Filename) returns signal metadata from the specified Parquet file as a table. The table includes signal names and column indices.

    When a JSON sidecar file with the same name as the Parquet file exists in the same folder, the table also includes block path, model, dimensions, and port index columns.

    To selectively import signals from a Parquet file based on signal names or column indices, use the SignalNames or ColumnIndices name-value argument in one of these functions:

    example

    Examples

    collapse all

    Get the signal names and column indices from a Parquet file, then selectively import a signal into the Simulation Data Inspector.

    Get the signal metadata from a Parquet file that contains simulation data.

    metadataTable = Simulink.sdi.Parquet.getSignalMetadata("mySimData.parquet")
    metadataTable =
    
      3×6 table
    
        Column Index    Signal Name    Block Path         Model    Dimensions    Port
        ____________    ___________    ________________   _____    __________    ____
    
             2          "Sig1"        "myModel/Out1"      ""        "1"          1
             4          "Sig2"        "myModel/Out2"      ""        "1"          1
             6          "Sig3"        "myModel/Scope"     ""        "1"          1
    

    To selectively import signals into the Simulation Data Inspector, use the signal names or column indices from the metadata table. For example, import only the signal named Sig1 into a new run.

    runID = Simulink.sdi.createRun("Imported_Data","file","mySimData.parquet",SignalNames="Sig1")

    Input Arguments

    collapse all

    Parquet filename, specified as a string or character vector. Include the file extension .parquet in the filename. If the file is not on the MATLAB path, include a full or relative path to the file.

    Output Arguments

    collapse all

    Signal metadata, returned as a table.

    When a JSON sidecar file with the same name as the Parquet file exists in the same folder, the table contains these columns:

    • Column Index — Column index of the signal data in the Parquet file

    • Signal Name — Signal name

    • Block Path — Block path of the signal source

    • Model — Model name

    • Dimensions — Signal dimensions

    • Port — Port index

    If no matching JSON sidecar file exists, the table contains only the Column Index and Signal Name columns.

    Version History

    Introduced in R2026b