Not expected results using datevec funcion
Show older comments
Dear colleagues,
I am writing from Brazil in order to get some help about datavec funciton.
I am using this fucntion to convert a date string data to vector format ([yy mm dd HH MM SS])
In Brazil date format is defined as follows: dd/mm/yy. I have a set of date data in two main formats. one without timestamp and another with timestamp, for instance: '13/12/2013' , '13/12/2013 00:15:00', respectively.
I get an error when I call the function to get the conversion:
Situation 1) result = datevec('13/12/2013', 'dd/mm/yyyy HH:MM:SS');
When I use the function with data with timestamp, as follows
Situation 2) result = datevec('13/12/2013 00:00:00', 'dd/mm/yyyy HH:MM:SS');
or
Situation 3) result = datevec('13/12/2013 00:15:00', 'dd/mm/yyyy HH:MM:SS');
I get correct answer:
Anybody has some hint to handle situation 1?
I appreciate any help. Thanks all in advance.
Best regards, Luis.
Accepted Answer
More Answers (0)
Categories
Find more on Time Series Objects in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!