Converting numeric elements to date
Ältere Kommentare anzeigen
I have converted date to serial number:
A= 10-Jan-2000
D = datenum(A)
D = 730495
And after doing some operation, I want to change (D) it back to the date format. But could not.
Is there any function to convert serial number to date format?
Akzeptierte Antwort
Weitere Antworten (1)
Ameer Hamza
am 30 Sep. 2020
Bearbeitet: Ameer Hamza
am 30 Sep. 2020
A = '10-Jan-2000';
D = datenum(A);
D = D + 10;
B = datestr(D);
Result
>> B
B =
'20-Jan-2000'
1 Kommentar
Milad Naderloo
am 30 Sep. 2020
Kategorien
Mehr zu Dates and Time finden Sie in Hilfe-Center und File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!