필터 지우기
필터 지우기

How to store multiple time data in a matrix?

조회 수: 1 (최근 30일)
Febin Benjamin
Febin Benjamin 2014년 6월 26일
댓글: Febin Benjamin 2014년 6월 26일
I have to store three time entities i.e 8.30a.m, 8.00a.m and 8.20a.m in a single matrix using datenum.
i tried doing this:
SCT= [datenum ('0000.01.00.08.30.00','yyyy.mm.dd.HH.MM.SS'),datenum ('0000.01.00.08.00.00','yyyy.mm.dd.HH.MM.SS'),datenum ('0000.01.00.08.20.00','yyyy.mm.dd.HH.MM.SS')];
but I am getting syntax error. Where am i going wrong? Please help.

채택된 답변

Mischa Kim
Mischa Kim 2014년 6월 26일
Febin, remove the empty spaces between the datenum commands and the round brackets:
datenum('0000.01.00.08.30.00','yyyy.mm.dd.HH.MM.SS')
rather than
datenum ('0000.01.00.08.30.00','yyyy.mm.dd.HH.MM.SS')
  댓글 수: 1
Febin Benjamin
Febin Benjamin 2014년 6월 26일
it worked! So silly of me to not notice that :-P Thanx Mischa!

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Time Series Objects에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by