Skip to content

The ethiodate package offers a fast, reliable, and user-friendly solution for converting dates between the Gregorian and Ethiopian calendar systems directly within Stata. Built in Mata for maximum computational efficiency, it provides super-fast date conversions.

License

Notifications You must be signed in to change notification settings

GutUrago/stata-ethiodate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ethiodate: Ethiopian Date Conversion Utilities for Stata

version Stata License: GPL v3

The ethiodate package offers a fast, reliable, and user-friendly solution for converting dates between the Gregorian and Ethiopian calendar systems directly within Stata. Built in Mata for maximum computational efficiency, it provides super-fast date conversions.


🚀 Installation

You can install or update the latest version of ethiodate directly from GitHub using:

net install ethiodate, from("https://raw.githubusercontent.com/GutUrago/stata-ethiodate/main/") replace

This will download and install all necessary files.


📦 Available Commands

to_gregorian

Converts Ethiopian calendar date variables (year, month, day) to a single Gregorian Stata date.

to_gregorian eth_year eth_month eth_day, gre_date(newvar)
  • eth_year, eth_month, and eth_day: numeric variables with Ethiopian date components.
  • gre_date(): name of the new Gregorian Stata date variable to create.

Example:

to_gregorian eth_yr eth_mo eth_dy, gre_date(greg_date)

to_ethiopian

Converts Gregorian calendar date variable to Ethiopian date components: year, month, day.

to_ethiopian gre_date, eth_year(newvar) eth_month(newvar) eth_day(newvar)
  • eth_year, eth_month, and eth_day: new numeric variables name of Ethiopian date components.
  • gre_date(): name of the Gregorian Stata date variable to convert.

Example:

to_gregorian eth_yr eth_mo eth_dy, gre_date(greg_date)
to_ethiopian greg_date

📖 Help

To get detailed documentation in Stata, type:

help ethiodate
help to_gregorian
help to_ethiopian

📌 Features

  • Fully vectorized, efficient and precise date conversion
  • Supports use within data cleaning and transformation pipelines
  • Compatible with Stata 10.0 and later
  • Clear help files and user instructions

👨‍💻 Author

Gutama Girja Urago
Research Analyst at Laterite Consulting PLC

LinkedIn | GitHub


🛠 Contributing

Contributions, feedback, and issue reports are welcome! Please open a pull request or submit an issue via the GitHub repository.

About

The ethiodate package offers a fast, reliable, and user-friendly solution for converting dates between the Gregorian and Ethiopian calendar systems directly within Stata. Built in Mata for maximum computational efficiency, it provides super-fast date conversions.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published