OPEN-SOURCE SCRIPT
Gold Price Cambodian Units - LFT.Trader

This indicator is specifically designed for gold traders and investors in the Cambodian market. It bridges the gap between the global gold market (priced in Troy Ounces) and the local Cambodian measurement system.
It provides a live-updating table on your chart that converts the current XAU/USD price into Damlung (ដំឡឹង), Chi (ជី), and Hun (ហ៊ុន).
Measurement Logic
To ensure accuracy, the script uses the standard international-to-local conversion:
1 Damlung (ដំឡឹង) = 37.5 Grams
1 Troy Ounce ≈ 31.1034768 Grams
1 Damlung ≈ 1.20565 Troy Ounces
1 Damlung = 10 Chi (ជី)
1 Chi = 10 Hun (ហ៊ុន)
Key Features
✅ Live Updates: Calculations refresh instantly with every price movement on the XAUUSD chart.
✅ Dual Currency Display: View prices in both USD and Cambodian Riel (KHR).
✅ Customizable Exchange Rate: Since local market rates for USD/KHR can vary from official bank rates, you can manually set your preferred exchange rate in the settings.
✅ Flexible UI: Choose from 9 different positions on your chart to place the table (Top, Middle, Bottom — Left, Center, Right).
✅ Toggle KHR Column: Hide or show the Riel column depending on your preference.
✅ Clean Formatting: Prices include thousands separators (commas) and decimal points for high-precision viewing.
How to Use
Add the indicator to a Gold (XAUUSD) chart.
Open the Settings to adjust the table position or text size.
Input the current local USD/KHR exchange rate to get an accurate Riel price.
Use the "Show Price (KHR)" checkbox to simplify the table if you only need USD values.
Disclaimer
This tool is for informational purposes only. Local gold shop premiums and spreads may vary. Always verify prices with your local dealer before making financial decisions.
It provides a live-updating table on your chart that converts the current XAU/USD price into Damlung (ដំឡឹង), Chi (ជី), and Hun (ហ៊ុន).
Measurement Logic
To ensure accuracy, the script uses the standard international-to-local conversion:
1 Damlung (ដំឡឹង) = 37.5 Grams
1 Troy Ounce ≈ 31.1034768 Grams
1 Damlung ≈ 1.20565 Troy Ounces
1 Damlung = 10 Chi (ជី)
1 Chi = 10 Hun (ហ៊ុន)
Key Features
✅ Live Updates: Calculations refresh instantly with every price movement on the XAUUSD chart.
✅ Dual Currency Display: View prices in both USD and Cambodian Riel (KHR).
✅ Customizable Exchange Rate: Since local market rates for USD/KHR can vary from official bank rates, you can manually set your preferred exchange rate in the settings.
✅ Flexible UI: Choose from 9 different positions on your chart to place the table (Top, Middle, Bottom — Left, Center, Right).
✅ Toggle KHR Column: Hide or show the Riel column depending on your preference.
✅ Clean Formatting: Prices include thousands separators (commas) and decimal points for high-precision viewing.
How to Use
Add the indicator to a Gold (XAUUSD) chart.
Open the Settings to adjust the table position or text size.
Input the current local USD/KHR exchange rate to get an accurate Riel price.
Use the "Show Price (KHR)" checkbox to simplify the table if you only need USD values.
Disclaimer
This tool is for informational purposes only. Local gold shop premiums and spreads may vary. Always verify prices with your local dealer before making financial decisions.
Script de código abierto
Fiel al espíritu de TradingView, el creador de este script lo ha convertido en código abierto, para que los traders puedan revisar y verificar su funcionalidad. ¡Enhorabuena al autor! Aunque puede utilizarlo de forma gratuita, recuerde que cualquier republicación del código está sujeta a nuestras Normas internas.
Exención de responsabilidad
La información y las publicaciones no constituyen, ni deben considerarse como, asesoramiento o recomendaciones financieras, de inversión, de trading u otro tipo, proporcionadas o respaldadas por TradingView. Obtenga más información en Condiciones de uso.
Script de código abierto
Fiel al espíritu de TradingView, el creador de este script lo ha convertido en código abierto, para que los traders puedan revisar y verificar su funcionalidad. ¡Enhorabuena al autor! Aunque puede utilizarlo de forma gratuita, recuerde que cualquier republicación del código está sujeta a nuestras Normas internas.
Exención de responsabilidad
La información y las publicaciones no constituyen, ni deben considerarse como, asesoramiento o recomendaciones financieras, de inversión, de trading u otro tipo, proporcionadas o respaldadas por TradingView. Obtenga más información en Condiciones de uso.