Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More โ†’
Socket
Sign inDemoInstall
Socket

korean-lunar-calendar

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

korean-lunar-calendar

Korean Lunar Calendar

  • 0.3.1
  • PyPI
  • Socket score

Maintainers
1

korean_lunar_calendar_py

===========================

ํ•œ๊ตญ ์–‘์Œ๋ ฅ ๋ณ€ํ™˜

Overview

^^^^^^^^

Here is a library to convert Korean lunar-calendar to Gregorian

calendar.

Korean calendar and Chinese calendar is same lunar calendar but have

different date.

This follow the KARI(Korea Astronomy and Space Science Institute)

ํ•œ๊ตญ ์–‘์Œ๋ ฅ ๋ณ€ํ™˜ (ํ•œ๊ตญ์ฒœ๋ฌธ์—ฐ๊ตฌ์› ๊ธฐ์ค€) - ๋„คํŠธ์›Œํฌ ์—ฐ๊ฒฐ ๋ถˆํ•„์š”

์Œ๋ ฅ ๋ณ€ํ™˜์€ 1000๋…„ 01์›” 01์ผ ๋ถ€ํ„ฐ 2050๋…„ 11์›” 18์ผ๊นŒ์ง€ ์ง€์›

์–‘๋ ฅ ๋ณ€ํ™˜์€ 1000๋…„ 02์›” 13์ผ ๋ถ€ํ„ฐ 2050๋…„ 12์›” 31์ผ๊นŒ์ง€ ์ง€์›

::

Gregorian calendar (1000-02-13 ~ 2050-12-31) <--> Korean lunar-calendar (1000-01-01 ~ 2050-11-18)

Install

^^^^^^^

pip install korean_lunar_calendar

To use

^^^^^^

(0) import module

.. code:: python



    from korean_lunar_calendar import KoreanLunarCalendar

(1) Korean Solar Date -> Korean Lunar Date (์–‘๋ ฅย -> ์Œ๋ ฅ)

.. code:: python



    calendar = KoreanLunarCalendar()

    # params : year(๋…„), month(์›”), day(์ผ)

    calendar.setSolarDate(2017, 6, 24)

    # Lunar Date (ISO Format)

    print(calendar.LunarIsoFormat())

    # Korean GapJa String

    print(calendar.getGapJaString())

    # Chinese GapJa String

    print(calendar.getChineseGapJaString())

::

[Result]

2017-05-01 Intercalation

์ •์œ ๋…„ ๋ณ‘์˜ค์›” ์ž„์˜ค์ผ (์œค์›”)

ไธ้…‰ๅนด ไธ™ๅˆๆœˆ ๅฃฌๅˆๆ—ฅ (้–ๆœˆ)

(2) Korean Lunar Date -> Korean Solar Date (์Œ๋ ฅย -> ์–‘๋ ฅ)

.. code:: python



    # params : year(๋…„), month(์›”), day(์ผ), intercalation(์œค๋‹ฌ์—ฌ๋ถ€)

    calendar.setLunarDate(1956, 1, 21, False)

    # Solar Date (ISO Format)

    print(calendar.SolarIsoFormat())

    # Korean GapJa String

    print(calendar.getGapJaString())

    # Chinese GapJa String

    print(calendar.getChineseGapJaString())

::

[Result]

1956-03-03

๋ณ‘์‹ ๋…„ ๊ฒฝ์ธ์›” ๊ธฐ์‚ฌ์ผ

ไธ™็”ณๅนด ๅบšๅฏ…ๆœˆ ๅทฑๅทณๆ—ฅ

Keywords

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with โšก๏ธ by Socket Inc