L2 Support Engineer | Lusaka Province, Zambia
April 6, 2025
In March 2025, I embarked on an exciting project to develop a Zambia Copper Prices Forecast Tool, designed to predict future copper prices in both USD and ZMW, as well as forecast the ZMW/USD exchange rate. As an L2 Support Engineer at NetOne Zambia, I have always been passionate about leveraging technology to solve real-world problems, and this tool is a step toward providing valuable economic insights for Zambia, a country where copper is a cornerstone of the economy.
The tool, which I developed using Python and Streamlit, allows users to upload historical data for copper prices (in USD/lb) and ZMW/USD exchange rates, then forecasts prices and rates for up to 30 days beyond March 28, 2025, the last date in the dataset. It is a practical solution for stakeholders in Zambia’s mining sector, helping them anticipate market trends and make informed decisions. You can try the tool yourself at copper-prices-forecast-zm.streamlit.app.
The development process involved several key steps. First, I used Streamlit to create an interactive web app where users can upload two Excel files: copper_fallback.xlsx
for copper prices and zm_fallback.xlsx
for exchange rates. Both files must contain a Date column (in YYYY-MM-DD format) and a Close column (for the closing price or rate). The app aligns the data by date, ensuring that copper prices and exchange rates match up, for example, the exchange rate on 28/03/2025 was 28.6817 ZMW/USD.
The forecasting logic is based on a simple yet effective trend analysis. Here is how it works:
The tool is user-friendly, with detailed instructions on how to format and upload data, including where to source historical data (e.g., MacroTrends for copper prices, Yahoo Finance for exchange rates). It also validates the data, ensuring the last date is 28/03/2025 and that there are enough data points (at least 3) for forecasting. The result is a practical tool that provides actionable insights for Zambia’s copper industry, reflecting my commitment to using tech for economic impact.