I have an entry "2017-10-26 06-PM" How can I transform this entry into a datetime format that Matlab can understand?

 採用された回答

Sean de Wolski
Sean de Wolski 2018 年 6 月 14 日
編集済み: Sean de Wolski 2018 年 6 月 14 日

0 投票

datetime("2017-10-26 06-PM",'InputFormat','yyyy-MM-dd hh-aa')

3 件のコメント

alpedhuez
alpedhuez 2018 年 6 月 14 日
Thank you. I have a table A with the entries of the first column are of the format "2017-10-26 06-PM." How can I transform this first column into datetime format?
Guillaume
Guillaume 2018 年 6 月 14 日
exactly the same way:
yourtable.columnname = datetime(yourtable.columname, 'InputFormat', 'yyyy-MM-dd hh-aa')
alpedhuez
alpedhuez 2018 年 6 月 14 日
Great help.

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

その他の回答 (0 件)

カテゴリ

ヘルプ センター および File Exchange で Dates and Time についてさらに検索

製品

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by