Tall table from multiple tables in different .MAT files

7 ビュー (過去 30 日間)
Patrick Aoun
Patrick Aoun 2017 年 8 月 19 日
編集済み: Walter Roberson 2017 年 10 月 17 日
I have a ton of separate .mat files, each containing a single table. They have the same variables, and same format for each variable. Combined, they do not fit into memory.
Is there a way to create a datastore or a tall table from these? Tried using datastore but, surprisingly, there doesn't seem to be an option for this.
I realize one option would be to loop through these, "convert" them to CSV, and make a datastore from this. This is my backup plan.
Thanks

回答 (2 件)

Krishna Bindumadhavan
Krishna Bindumadhavan 2017 年 8 月 22 日
編集済み: Walter Roberson 2017 年 10 月 17 日
The procedure that you have mentioned in the question (converting the files to .csv and then making a datastore) should work. Alternatively, you can also use a FileDatastore (used for custom file formats) as outlined in the documentation here :
The example provided in the documentation shows how you can use FileDatastore with .mat files.
Hope this helps!

Anandan Rangasamy
Anandan Rangasamy 2017 年 10 月 17 日
I would suggest you to set UniformRead to true when creating FileDatastore to get a tall table. Here is an example.

カテゴリ

Help Center および File ExchangeLarge Files and Big Data についてさらに検索

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by