mdfChannelInfo
Description
returns a table of information about all channels in the specified MDF file.infoTable
= mdfChannelInfo(mdfFileName
)
allows specified name-value arguments to filter on specific channels and channel groups, and
determine the amount of metadata returned.infoTable
= mdfChannelInfo(___,Name=Value
)
Examples
Get Channel Information from MDF File
Access the channel information in an MDF file.
Get information on all channels.
ci = mdfChannelInfo("VehicleData.mf4")
ci = 12×13 table Name GroupNumber GroupNumSamples GroupAcquisitionName GroupComment GroupSourceName GroupSourcePath DisplayName Unit Comment ExtendedNamePrefix SourceName SourcePath _________________ ___________ _______________ ____________________ ___________________________________________________________________________ _______________ _______________ ___________ ___________ ___________ __________________ ___________ ___________ "AirFlow" 2 92033 <undefined> Simulation of engine gas dynamics. <undefined> <undefined> "" g/s <undefined> <undefined> <undefined> <undefined> "Brake" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" ft*lbf <undefined> <undefined> <undefined> <undefined> "EngineRPM" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" rpm <undefined> <undefined> <undefined> <undefined> "FuelRate" 2 92033 <undefined> Simulation of engine gas dynamics. <undefined> <undefined> "" g/s <undefined> <undefined> <undefined> <undefined> "Gear" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" <undefined> <undefined> <undefined> <undefined> <undefined> "ImpellerTorque" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" ft*lbf <undefined> <undefined> <undefined> <undefined> "OutputTorque" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" ft*lbf <undefined> <undefined> <undefined> <undefined> "Throttle" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" % <undefined> <undefined> <undefined> <undefined> "TransmissionRPM" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" rpm <undefined> <undefined> <undefined> <undefined> "VehicleSpeed" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" mph <undefined> <undefined> <undefined> <undefined> "time" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" s <undefined> <undefined> <undefined> <undefined> "time" 2 92033 <undefined> Simulation of engine gas dynamics. <undefined> <undefined> "" s <undefined> <undefined> <undefined> <undefined>
View information for specific channels.
ci = mdfChannelInfo("VehicleData.mf4",Channel="*Torque")
ci = 2×13 table Name GroupNumber GroupNumSamples GroupAcquisitionName GroupComment GroupSourceName GroupSourcePath DisplayName Unit Comment ExtendedNamePrefix SourceName SourcePath ________________ ___________ _______________ ____________________ ___________________________________________________________________________ _______________ _______________ ___________ ______ ___________ __________________ ___________ ___________ "ImpellerTorque" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" ft*lbf <undefined> <undefined> <undefined> <undefined> "OutputTorque" 1 751 <undefined> Simulation of an automatic transmission controller during passing maneuver. <undefined> <undefined> "" ft*lbf <undefined> <undefined> <undefined> <undefined>
View channel information in one channel group.
ci = mdfChannelInfo("VehicleData.mf4",GroupNumber=2)
ci = 3×13 table Name GroupNumber GroupNumSamples GroupAcquisitionName GroupComment GroupSourceName GroupSourcePath DisplayName Unit Comment ExtendedNamePrefix SourceName SourcePath __________ ___________ _______________ ____________________ __________________________________ _______________ _______________ ___________ ____ ___________ __________________ ___________ ___________ "AirFlow" 2 92033 <undefined> Simulation of engine gas dynamics. <undefined> <undefined> "" g/s <undefined> <undefined> <undefined> <undefined> "FuelRate" 2 92033 <undefined> Simulation of engine gas dynamics. <undefined> <undefined> "" g/s <undefined> <undefined> <undefined> <undefined> "time" 2 92033 <undefined> Simulation of engine gas dynamics. <undefined> <undefined> "" s <undefined> <undefined> <undefined> <undefined>
Request additional metadata on multiple channel matches. View only the first and additional table columns.
ci = mdfChannelInfo("VehicleData.mf4",Channel=["*Torque","*Rate"],AdditionalMetadata=true); ci(:,[1,14:25])
ans = 3×13 table Name Type SyncType DataType NumBits ComponentType CompositionType ConversionType SourceComment SourceType SourceBusType SourceBusChannelNumber SourceSimulated ________________ ___________ ________ ________________ _______ _____________ _______________ ______________ _____________ ___________ _____________ ______________________ _______________ "FuelRate" FixedLength None RealLittleEndian 64 None None Unspecified "" Unspecified Unspecified 0 false "ImpellerTorque" FixedLength None RealLittleEndian 64 None None Unspecified "" Unspecified Unspecified 0 false "OutputTorque" FixedLength None RealLittleEndian 64 None None Unspecified "" Unspecified Unspecified 0 false
Input Arguments
mdfFileName
— MDF file name
string | char vector
MDF file name, specified as a string or character vector, including the necessary full or relative path. You can use a URL to specify a file on a remote server.
Depending on the location you are accessing,
mdfFileName
can take one of these forms.
Location | Form | ||||||||
---|---|---|---|---|---|---|---|---|---|
Current folder or MATLAB® path | To access a file in the current folder or MATLAB path, specify the
name of the file in Example:
| ||||||||
Other folders | To access a file in a folder other than the current folder, specify
the full or relative path name in
Example:
Example:
| ||||||||
Remote locations | To access a file in a remote location,
Based on the remote location,
For more information, see Work with Remote Data. Example:
|
Data Types: string
| char
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.
Before R2021a, use commas to separate each name and value, and enclose
Name
in quotes.
Example: GroupNumber=2
GroupNumber
— Channel group number
numeric
Channel group number, specified as a numeric scalar for one group, or numeric vector for multiple groups. The function returns channels found only in these specified channel groups. If unspecified, metadata for all channel groups are returned.
Example: GroupNumber=[1,2]
Data Types: single
| double
| int8
| int16
| int32
| int64
| uint8
| uint16
| uint32
| uint64
Channel
— Channel names
string | char | cell
Channel names, specified as a string or array of strings, or as a character vector or cell array of character vectors. Use an array to match on any of multiple channel names. Wildcards allow partial matching. If unspecified, metadata for all channels are returned.
Example: Channel=["*Rate","*Speed"]
Data Types: string
| char
| cell
AdditionalMetadata
— Return additional metadata
false
(default) | true
Return additional channel metadata, specified as true
or
false
.
Example: AdditionalMetadata=true
Data Types: logical
Output Arguments
infoTable
— Channel information
table
Channel information returned in a table of channels.
Version History
Introduced in R2023aR2023a: Support for Remote File URLs
You can directly access MDF file data stored at remote locations, including Amazon S3, Azure® Blob Storage, and HDFS.
MATLAB Command
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list:
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
- América Latina (Español)
- Canada (English)
- United States (English)
Europe
- Belgium (English)
- Denmark (English)
- Deutschland (Deutsch)
- España (Español)
- Finland (English)
- France (Français)
- Ireland (English)
- Italia (Italiano)
- Luxembourg (English)
- Netherlands (English)
- Norway (English)
- Österreich (Deutsch)
- Portugal (English)
- Sweden (English)
- Switzerland
- United Kingdom (English)