Univeristy of Alabama in Huntsville

UAH LTG IDL Library

IDL Routines from Phillip Bitzer and UAH Lightning Group

summary     class     fields     routine details     file attributes

misc/time/

pmb_unix2human.pro

Time


Given a (or array) of Unix times, convert these into a human format. Nominally returns a dictionary with entries corresponding to year, month, etc.

Unix time is the number of seconds from midnight on Jan 1, 1970.

Rewritten from legacy code convert_utc_to_human, which was based on original code retrieved on 07-10-08 from http://www.arm.gov/data/time.stm

Examples

Provide an example

Author information

Author

Phillip M. Bitzer, University of Alabama in Huntsville, pm.bitzer "AT" uah.edu

History

Modification History:

First written from legacy: Apr 4, 2017

Other file information

Uses:

None

Routines

top pmb_unix2human

result = pmb_unix2human(unixTime [, /tString] [, /hudat])

Calculate the human time from Unix time.

Return value

A dictionary with entries year, month, day, hour, minute, second...unless one of the keywords is set. On error, NaN is returned.

Parameters

unixTime in required type=numeric (array)

The Unix time you wish to convert

Keywords

tString in optional type=boolean

If true, return a string array of the form YYYYMMDDTHHMMSS. Seconds will be truncated

hudat in optional type=boolean

If true, return a string array of the form MM/DD/YY HH:MM:SS. Seconds will be truncated

Other attributes

Uses:

OtherRoutines

File attributes

Modification date: Fri Apr 21 15:30:34 2017
Lines: 50
Docformat: rst rst