Return Various Periods from a Time Vector

DESCRIPTION:

Extract various time of day periods from a time vector as numbers.

USAGE:

hours(x) 
minutes(x) 
seconds(x) 
yeardays(x) 

REQUIRED ARGUMENTS:

x
the timeDate object to extract periods from.

VALUE:

a numeric vector hours, minutes, seconds, or year-days of x for the respective function. Hours are integers between 0 and 23, minutes are integers between 0 and 59, and seconds are numbers including the fractions of a second. Yeardays are the day number of the year (a number between 1 and 366).

SEE ALSO:

, .

EXAMPLES:

x <- timeDate(c("1/1/1998 3:05:23.4", "5/10/2005 2:15:11.234 PM")) 
hours(x) 
minutes(x) 
seconds(x) 
yeardays(x)