|
From: | przemek klosowski |
Subject: | Re: read date from xls file |
Date: | Tue, 31 Aug 2021 16:45:35 -0400 |
User-agent: | Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 |
I have a xlsx file called gffft (attached) containing two columns: the first a date column under the format mm/dd/yyyy and the second column is reserved for the values of a series. I would like to read the date column and plot the series where the x-axis is the date column but rather in the following format: dd-mmm-yyyy.
https://octave.discourse.group/t/convert-date-to-number-from-excel/194/3
You will probably need to load (and maybe install beforehand) the
IO package to use xlsread(), but it seems to read your data.
As Doug says above, the XLS dates use a different epoch than
Octave, so you need to add 693960, and then you can print them out
by using datestr()
datestr(31959+693960,'dd-mmm-yyyy')
ans = 01-Jul-1987
[Prev in Thread] | Current Thread | [Next in Thread] |