1
$\begingroup$

My problem is that I want use PGFplot in $\LaTeX$ to draw my graphs, which x axis is a date. Therefore the output file has to have one column "UTC time" (YYYY-MM-DD hh:mm:ss) and the second one is the corresponding data list.

Would it be possible to specify the date format of Export[] ?

$\endgroup$
  • $\begingroup$ Use DateString to get the right formatting. $\endgroup$ – C. E. Jul 30 '14 at 16:11
2
$\begingroup$

So the solution would be (thanks to Pickett)

DateString[#, {"Year", "-", "Month", "-", "Day", " ", "Hour", ":", "Minute", ":", "Second"}]&/@dates

Once the transformation done, export the thing !

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.