Write timetable data to MDF-file
writes a timetable of MDF data to a new channel group appended at the end of the specified
MDF-file. The timetable can also contain channel group and channel metadata, which you can
add using the function
mdfAddChannelGroupMetadata before performing the
write operation. If the file does not exist, the function creates it.
writes data to the specified channel group index. If unspecified, data is written to a new
channel group appended to the end of existing channel groups.
Write Data to a Channel Group in an MDF-file
Write data from a timetable to a specific channel group index in an MDF-file.
mdfFileName — MDF-file name
string | char
MDF-file name to write to, specified as a string or character vector. The file name
can be a relative or absolute path. The name must include the extension
.mf4. If the
file does not exist, the function creates it.
Depending on the location you are accessing,
mdfFileName can take one of these forms.
|Current folder or MATLAB® path|
To access a file in the current folder or MATLAB path, specify the
name of the file in
To access a file in a folder other than the current folder, specify
the full or relative path name in
To access a file in a remote location,
Based on the remote location,
For more information, see Work with Remote Data.
mdfData — Timetable of MDF data to write
Data, specified as a timetable, to write to the MDF-file.
mdfWritefunction does not support writing array channels or structure channels.
When overwriting an existing channel, use a timetable that was created by the
readfunction with the option
IncludeMetadata=true. Do not remove any timetable custom properties returned by the
When overwriting an existing channel, the
ChannelReadOptionproperty in the timetable custom properties is used internally to keep track of the kind of conversion rule applied during the read. Do not modify this custom property in the timetable.
When writing a new channel to an MDF-file, the
mdfWritefunction does not support writing data with conversion rules. Only raw values can be written to new channels.
Version HistoryIntroduced in R2022a
R2023a: Support for Remote File URLs
You can directly access MDF-file data stored at remote locations, including Amazon S3, Azure® Blob Storage, and HDFS.