Pulling in data exported from the Data Inspector into another model
1 次查看(过去 30 天)
显示 更早的评论
I am trying to export a set of signals as Timeseries data using the Simulation Data Inpector (Matlab R2017b) to be used as an input to a Simulink model running R2022b. My current solution is to save it as a .mat file. I then want to use this data as an input for the model that I have updated to Matlab R2022b. I have tried using the 'signal editor block' to bring them in from the .mat loaded into the workspace, but that triggers the data incorrectly. I have tried using the 'from file' and 'from workspace' blocks but the .mat data saved from the Simulation Data Inspector has other data besides the signals and timeseries data. I know I could write a script to remove the unwanted data then use the 'from workspace' block, but I wanted to know if there is a quicker way to do this with the data as formated.
0 个评论
回答(1 个)
Sulaymon Eshkabilov
2024-1-8
There are a few options that can be used to store simulation data from a Simulink model:
(1) [To File] to store data in .mat file: Timeseries or Array
(2) [To Workspace] and data type can be specified: Timeseries (by default), Array, Structure time series, Structure or Array
(3) [Scope]: Configuration Properties --> Logging --> Log data to workspace: Dataset, Structure time series, Structure or Array
You can choose which one best suits for your model.
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Sources 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!