find a value in a vector of type char

i have vector composed from date and time for exemple:
%
date_time=[date time]
date_time=['06.09.2010' '1:18.25']
date is a 40000*1 cell
time is a 40000*1 cell
how could i find the index of a time_date= '7.5.2012' '2:20:59' with the function find or any other function?
thank you

댓글 수: 1

Jan
Jan 2012년 11월 15일
편집: Jan 2012년 11월 15일
Are you looking for '7.5.2012' '2:20:59', while the data contain '07.07.2012' '02:20:59'? Using leading zeros would be a marvelous idea obviously.

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

 채택된 답변

Andrei Bobrov
Andrei Bobrov 2012년 11월 15일

0 개 추천

ismember(data_time,{'7.5.2012' '2:20:59'},'rows');

추가 답변 (1개)

카테고리

도움말 센터File Exchange에서 Dates and Time에 대해 자세히 알아보기

태그

질문:

2012년 11월 15일

Community Treasure Hunt

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

Start Hunting!

Translated by