주요 콘텐츠

UserImporter

R2026b

Define custom data-channel mappings for K and C file import

Since R2026b

Description

importer = vdynsuspension.import.UserImporter(dataFormat) creates a UserImporter object that defines custom channel-name-to-variable mappings for K and C data file import. Use the importer to customize how .tab or .txt file channels map to standard K and C variable names.

example

Input Arguments

expand all

File format for custom import, specified as ".tab" or ".txt". The format determines the prefix used for test info and test variable mappings.

Data Types: string

Properties

expand all

Channel-name-to-variable mapping dictionary, specified as a containers.Map object. The keys are channel names from the data file and the values define the corresponding K and C variable paths. The constructor initializes the dictionary with standard vehicle info, test info, and wheel/suspension measurement mappings.

File format identifier, returned as ".tab" or ".txt".

Temporarily stored raw imported data, returned as a structure. This property holds the raw data read from the file before the object applies the mapping.

Object Functions

MethodDescription

writeMapToMFile

Export the current mapping to a MATLAB script

constructMapFromMFile

Import a mapping from a MATLAB script file

Examples

expand all

If the import method cannot find a matching data structure in your .tab or .txt file, create a UserImporter to define a custom channel mapping.

importer = vdynsuspension.import.UserImporter(".tab");

Export the mapping to a MATLAB script file to review and edit the key-value pairs. Do not modify the key strings.

importer.writeMapToMFile("myMapping");

After editing the generated myMapping.m file to match your data file channel names, reload the mapping into the importer.

importer.constructMapFromMFile("myMapping.m");

Create a K and C service with the custom importer and import data.

knc = kncSuspension(CustomMapping=importer, Description="K and C custom import");
knc.import("myData.tab", TestType="bounce", FrontAntiRollBar=true, RearAntiRollBar=true)

Version History

Introduced in R2026b