Learn R Programming

phenology (version 4.0.4)

convert.tz: Convert one Date-Time from one timezone to another

Description

Convert one Date-Time from one timezone to another. Available timezones can be shown using OlsonNames()

Usage

convert.tz(x, tz = Sys.timezone())

Arguments

x
The date-time in POSIXlt or POSIXct format
tz
The timezone

Value

  • A POSIXlt date converted

Details

convert.tz Convert one Date-Time from one timezone to another

Examples

Run this code
d <- as.POSIXlt("2010-01-01 17:34:20", tz="UTC")
convert.tz(d, tz="America/Guatemala")

Run the code above in your browser using DataLab