필터 지우기
필터 지우기

Transforming Timestamps column into various columns

조회 수: 1 (최근 30일)
João
João 2013년 11월 26일
댓글: João 2013년 12월 6일
Hi all,
I'm with a problem and can't find the solution for it, hope you can help me.
I have this column;
Timestamps
01/01/2012 09:00
01/01/2012 10:00
01/01/2012 11:00
and now I want to slip it into 4 different columns with:
Day Month Year Hour
01 01 2012 9
The file is in excel.
Thanks.

채택된 답변

Andrei Bobrov
Andrei Bobrov 2013년 11월 26일
data = {'01/01/2012 09:00'
'01/01/2012 10:00'
'01/01/2012 11:00'};
v = datevec(data);
out = v(:,1:4);

추가 답변 (0개)

카테고리

Help CenterFile 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