Converting numeric elements to date
Mostra commenti meno recenti
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?
Risposta accettata
Più risposte (1)
Ameer Hamza
il 30 Set 2020
Modificato: Ameer Hamza
il 30 Set 2020
A = '10-Jan-2000';
D = datenum(A);
D = D + 10;
B = datestr(D);
Result
>> B
B =
'20-Jan-2000'
1 Commento
Milad Naderloo
il 30 Set 2020
Categorie
Scopri di più su Dates and Time in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!