Learn R Programming

datagovsgR (version 0.3.0)

uvi: UVI(Ultra-violet Index)

Description

This functions calls upon the UVI API from data.gov.sg and returns the UVI value for the given data-time. This data provided by the API is updated hourly.

Usage

uvi(date_time = "")

Arguments

date_time

Defaults to current (SGD) time. Format: YYYY-MM-DDTHH:MM:SS

Value

A dataframe containing the UVI for the given date-time

Details

Note that there is only information on the UVI between 0700 and 1900. Entering a date-time outside of the range would return the UVI of the closest date time instead.

Examples

Run this code
# NOT RUN {
uvi()
uvi(date_time = "2018-10-10T15:00:00")
uvi(date_time = "2019-04-01T09:00:00")
# }

Run the code above in your browser using DataLab