Skip to contents

Small functions that helps to extract parts of Ethiopian date objects.

Usage

eth_year(x)

eth_month(x)

eth_monthname(x, lang = c("lat", "amh", "en"), abbreviate = FALSE)

eth_day(x)

eth_weekday(x, lang = c("lat", "amh", "en"), abbreviate = FALSE)

Arguments

x

a vector of an Ethiopian date object

lang

a language. 'amh' for Amharic, 'lat' for Amharic written in Latin alphabets and 'en' for English

abbreviate

Do you want to get an abbreviated month or weekday names?

Value

a vector

Author

Gutama Girja Urago

Examples

today <- eth_date(Sys.Date())
eth_year(today)
#> [1] 2017
eth_month(today)
#> [1] 8
eth_monthname(today)
#> [1] "Miyazya"
eth_day(today)
#> [1] 28
eth_weekday(today)
#> [1] "Maksegno"