フィルターのクリア

how to merge multiple timetable

12 ビュー (過去 30 日間)
Sehoon Chang
Sehoon Chang 2020 年 8 月 21 日
コメント済み: Cris LaPierre 2020 年 8 月 23 日
dear advisers,
i have multiple timetables with different timestamps (yyyy-mm-dd hh:mm), but within a same time period.
I wish to merge multiple timetables into a single timetable, and the measurement recorded for each corresponding timestamps shall be organized in ascending order (e.g. 2020-08-01 0:00 , 2008-08-01 1:00, ....).
Thank you for your advice.

採用された回答

Cris LaPierre
Cris LaPierre 2020 年 8 月 23 日
You might be able to use synchronize. If you have more than 2 tables, you will need to use it multiple times.
  2 件のコメント
J. Alex Lee
J. Alex Lee 2020 年 8 月 23 日
Just a quick note this would probably require conversion of your tables into timetables first with table2timetable().
Also based on quick read of the docs, doesn't appear to have an option to behave more like a join, i.e., do not fill missing? Anyway I suppose it ultimately depends on exactly what the end objective is.
Cris LaPierre
Cris LaPierre 2020 年 8 月 23 日
The OP states they are using timetables.

サインインしてコメントする。

その他の回答 (1 件)

J. Alex Lee
J. Alex Lee 2020 年 8 月 21 日
編集済み: J. Alex Lee 2020 年 8 月 21 日
If the tables have the same columns, you should be able to simply vertically concatenate them and sort
t0 = sortrows(vertcat(t1,t2,t3))
  4 件のコメント
Sehoon Chang
Sehoon Chang 2020 年 8 月 22 日
yes, i meant the matlab 'table'.
What i meant by the measurement invertal (diff(timestamp)) is...
table_1 lists radiation value every 15 minutes and table_2 lists other measurements every hour.
Thanks alot for your help :)
J. Alex Lee
J. Alex Lee 2020 年 8 月 22 日
look into "innerjoin" and "outerjoin"

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeTables についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by