pythainlp.ancient
Modules
- pythainlp.ancient.aksonhan_to_current(word: str) str [source]
Convert AksonHan words to current Thai words
AksonHan (อักษรหัน) writes down two consonants for the spelling of the /a/ vowels. (สระ อะ).
Today, รร is an aksonHan word that is still used in Thai.
- Parameters:
word (str) – Thai word
- Returns:
Thai AksonHan to be converted to current Thai word
- Return type:
- Example:
from pythainlp.ancient import aksonhan_to_current print(aksonhan_to_current("จกก")) # output: จัก print(aksonhan_to_current("บงงคบบ")) # output: บังคับ print(aksonhan_to_current("สรรเพชญ")) # รร is still used. # output: สรรเพชญ
- pythainlp.ancient.convert_currency(value: float, from_unit: str) dict [source]
Convert ancient Thai currency to other units
เบี้ย (Bia)
อัฐ (At)
ไพ (Pi)
เฟื้อง (Feuang)
สลึง (Saleung)
บาท (Bath)
ตำลึง (Tamleung)
ชั่ง (Chang)
- See more:
- Parameters:
- Returns:
Thai currency
- Return type:
- Example:
from pythainlp.ancient import convert_currency print(convert_currency(8, "บาท")) # output: # { # 'เบี้ย': 51200.0, # 'อัฐ': 512.0, # 'ไพ': 256.0, # 'เฟื้อง': 64.0, # 'สลึง': 32.0, # 'บาท': 8.0, # 'ตำลึง': 2.0, # 'ชั่ง': 0.1 # }