Regression Analytics of the Nigerian National Currency: A Machine (Deep) Learning Predictive Mathematical Model
Regression Analytics of the Nigerian National Currency: A Machine (Deep) Learning Predictive Mathematical Model of Over thirty (1972-2018) year events.
I am in the process of using deep learning technology to reveal some patterns that has been recurring with respect to the Nigerian Naira. This would be followed by several Countries on the African Continent.
One of the major endpoints is to develop a full fledged African Journal that will publish findings of all the African member states economy, the current pitfalls to economic growth and sustainable development. Details shortly.
|Authored by: Oluwatobi Michael Owoeye, Principal Investigator, and Software Developer at Handsonlabs Software Academy.
Handsonlabs pronounced Hands-On-Labs, Software Academy, started as an idea or concept (small office home -SOHO) office in 2006 while Oluwatobi Michael Owoeye was enrolled in undergraduate degree in computer science. Then, he started consulting for undergraduates and post graduate students who needed computer program attaché to their individual thesis required before graduation. Later, in 2010, the first class of student’s were taught programming in Php.MySql Ogba Ikeja, Lagos, Nigeria. It was also founded & inspired on the ever increasing needs of Nigerian Students who are at disparity with the ever changing trends and advances of software engineering skills on demand in the 21st century workplace or labour market. In addition, come 2011, a centre was rolled out on clegg street, Western Avenue, Surulere, Lagos, Nigeria where it operated on evenings and weekend classes and consultations up until 2014. Thereafter, focus was shifted to deep research and development in the sciences, technology, education and health.
In 2016, Hands-On-Labs, Software Academy, formally became registered with Corporate Affairs Commission, Nigeria with registration number 246776, and in 2017, fully with Nigerian Federal Inland Revenue Service (FIRS) commission with Value Added Tax Number 20217104-0001, (MSTO-ALABA). Guaranty Trust Bank runs the corporate account for the firm. Hands-On-Labs, Software Academy is currently located in its own property at: 31/33 Yotomi Street, Carpenter Bus Stop, ilemba Awori, Iyana Igbede Road, Ajangbadi. Ojo. Lagos. Nigeria.
Hours of Operation: Mondays to Fridays: 4.30 pm to 9 pm daily.
Weekends: 10 am to 9pm and 3 pm to 7 pm ( Saturdays and Sundays respectively)
LinkedIn Handle: https://www.linkedin.com/in/oluwatobi-tobi-owoeye-15a6181b/
Facebook Handle: https://www.facebook.com/oluwatobi.owoeye.3
The National Currency of Nigeria is known as the Naira; it was introduced in 1973 by the central bank of Nigeria. Nigeria inherited the British pound at independence in 1960 from the Colonists before changing to its local currency. The country has been an Agro based Economy Nation from the pre and post period of independence. Groundnut pyramids, Tomatoes, Onions, Potatoes in the Northern part of the Country, Cocoa in the South West, Rubber, Palm Kernels, yam, Plantain in the South, and South East just to mention a few. Oil was discovered in Olobiri in the year 1956, the pre-period of the Nigerian Civil War. This discovery, a huge plus, normally should have been an added advantage to the Agricultural strength of the Nigerian Economy, which at that material time powerfully placed the exchange rate at 90k to One (1) USD.
However since 1986, Nigeria’s National currency, the Naira, has seriously been plummeting in scale and exchange rate against the US Dollar and other major World currencies. This on the other hand, came to the advantage of a lot of economic saboteurs and stunted the country’s socio-economic, educational growth as a potential African Country.
This research paper will attempt to make a quick Literature review of the history of the Nigerian currency up till date and for the first time ever, implement a forecast based on machine (deep) learning algorithms- a current day technological tool for making predictive models and higher insights based on previous datasets. I use support vector regression analysis to perform pattern recognition of trends and predict possible future valuations of the currency based on existing datasets. This will be succeeded by deep learning analytics on the literature review and using linear regression model on the Nigerian Naira against World’s major currencies, in both cases using open datasets.
Finally, I make an effective summary and implications.
Keywords: Nigeria, Naira, Regression, Machine Learning, Artificial Intelligence, Finance, Prediction, Mathematical Model, Nigerian President, Central Bank of Nigeria Computer Science, Artificial Intelligence, Computer Vision, Distributed/Parallel Computing, Machine Learning, Algorithms, Linear Regression, Support Vector Model, Economics, Dollar, Naira, Exchange, Nigerian President, Governor of Central Bank, Nigeria.
INTRODUCTION & BACKGROUND
Fig. 1 Image of Political Map of Nigeria.
Nigeria is Africa’s largest single black population. 2011/2014 census population statistics puts the country at over one hundred and seventy three million (173,000,000) people (this number combines more than the entire population of East Africa, for instance, a single city like Lagos State, Nigeria is equivalent to entire populations of Benin, Togo and Ghana). It is generally estimated that out of every five black African descent, two to three are likely to be Nigerian. Additionally, Nigeria Houses over two hundred and fifty (250) African cultures, dialects, tribes and unique ethnicities. For short, this country is massive, huge, and rich with yet untapped potential in many ramifications including human capital.
The literature review of events is blend of what every educated Nigerian who follows financial News trends is aware of. For instance, I was in Junior Secondary 2, in Lagos walking home one afternoon when I saw a tabloid headline captioned “Naira bows to the Dollar at twenty naira to a dollar” in 1992/1993 academic session.
In addition, for this research paper, I make use of Mat-lab Computing Software (2017b version) equipped with Classification Learner and Regression Learner tools respectively. Furthermore, I also made use of Central Bank of Nigeria’s  downloadable open dataset as reflected on the 14th of April, 2018.
HISTORICAL FACTS, OF THE NIGERIAN NAIRA
President Ibrahim Badamosi Babaginda-IBB (1985 to 1993)
The real trouble of the Nigerian Naira kicked off during this period after a lot of coup and counter coup deters. During Babaginda’s reign, Structural Adjustment programme (SAP), Second Tier Foreign Exchange Market (SFEM), which both introduced the parallel exchange market known as the black market were introduced. Following IBB’s exit in 1993, the Naira was already exchanging at seventeen (17) naira units to a US dollar. This can be proportionately represented as a 17% depreciation index in in compares to the US dollar. Furthermore, it is widely accepted that this was the beginning of Nigeria’s economic gloom as things worsened by the day for ordinary Nigerians on the streets and crime syndicates increased exponentially as a result of a weaker National currency that never produced industrialization but rather bankruptcy and untold debt, hardship to its citizens.
President Sanni Abacha (1993 to 1998)
Sanni Abacha came on board in 1993, during a time of political turmoil that engulfed the country from cancellation of June 12, 1992 Elections. At this time, the naira had slipped to twenty two (22) naira units to a US dollar. During his regime, the Autonomous Foreign Exchange Market (AFEM) came to light as a regulatory body to handle forex exchange. Handling the official rate was at an angle whilst handling the demand for the dollar was another. The other side was the un-restricted pull and urge to bring finished goods from overseas that could be locally produced for consumer utilities which invariably pushed the value of the naira exchange rate beyond the regulations of Nigeria’s Central Bank. This unrealistic scenery led to a loose margin that was well exploited by the parallel exchange market, known as the “Black Market”, and enormous exploitation by some banks who had direct access to buy from Nigeria’s AFEM, managed by Nigeria’s Central BANK, and in turn sell at ridiculous margins inimical to the country’s economic growth.
President Olusegun Obasanjo (Joseph Sanusi (CBN governor 1999 to 2004))
Between the exit of Sanni Abacha, the interim Government and the fresh installation of democracy in 1999 of President Olusegun Obasanjo, the dollar Naira exchange rate was already hitting close to 100 naira units to a dollar (100%) in depreciation. The fate of the naira was dwindling between 80 to 100 units to a single dollar between 1998 and 1999.
Joseph Sanusi, CBN Governor of Nigeria within 1999 to 2004, brought in Interbank Foreign Exchange Market (IFEM) who still kept the official exchange rate at wide margin to the parallel exchange market. Up until then, economic exploits of this odd margin of exchange rate kept heavy damage along its paths to the blare and disadvantage of the Nigerian people and economy.
Previous quack banks set up everywhere who did not care to invest in the real economy but rather blossomed by just leveraging on the difference between the official exchange rate and the parallel exchange market and helped ship stolen funds abroad for keeping were finally displaced. Meanwhile, Nigeria’s foreign debt rose exponentially and consumed its National foreign reserves prior to this period.
President Olusegun Obasanjo (II Term)
Chukwuma Soludo (2004-2009) Tenures
During the course of 2003, it would be recalled that oil prices inflated worldwide from $30 to $140 per barrel. This made Nigeria’s foreign reserve to rise exponentially giving birth to the Excess crude oil Account known as (ECA) with over $20 billion at some time in 2008. Soludo really had credits for synchronizing CBN, Bureau DE Change, Wire Rates and Interbank exchange values. He also made provision for local industries who required a foreign component or raw material to finish their production for consumption. One of the laudable achievements of former President Obasanjo Administration was the complete clearance of one of Nigeria’s long standing foreign debt (London-Paris Club).
In addition, during Soludo’s time, Naira gained 20% against the dollar based on actionable policies made by the incumbent Central Bank Governor. This also helped the economy to stabilize against the drop in oil prices in 2008, since Nigeria’s foreign reserve was about $62 billion at that material time. Soludo Chukwuma, also recapitalized Nigeria’s banks as a means of removing mushroom banks littering the entire country who were not making any meaningful impact on the Nigerian Economy. Soludo’s entry met the exchange rate at 127 Naira to 1 dollar, and his exit in 2009 left the exchange rate at 147 naira to a single dollar unit despite its gains of 20% in less than a year.
CBN Governor: Sanusi Lamido Sanusi, (June 2009-Feb 2014/15)
Governor Sanusi Lamido Sanusi, upon assumption of office in June 2009 quickly reinstated Interbank Exchange but had issues with maintaining the value of the Naira. He used early release of Government bonds for sale to stimulate consumer spending but this was to no avail as Nigeria’s real economic sector (Agricultural products, consumer goods) that complemented oil revenue in the late 1960s to early 1980s was still abandoned. Though, it was during Sanusi Lamido’s tenure that the country was placed on JP Morgan index. Nigerian Naira managed to sustain an exchange rate to 148 to a dollar unit. However by the time he too left office, in 2014, naira had taken a deeper plunge against the dollar to a value of 164 to a US dollar unit. In fact, between 2014 and 2016, Nigeria witnessed the greatest National currency devaluation with a time where dollar exchanged between an alarming 200 to 500 naira units to a single dollar currency.
President Mohammed Buhari,
CBN Governor Godwin Emeﬁele: Current Economic Index of Nigeria
The current CBN Governor of Nigeria, Godwin Emefiele, has directed a lock down on funding for goods that can be easily produced in Nigeria recently. One good thing he also did was synchronizing the parallel exchange rate with the official rate, thereby removing the “ghost” margin that wrecked the country for years.
Now, let’s do a little math logic. It is generally believed that $30 USD to bring up a single barrel of crude oil in Nigeria. If oil is being sold for $120, removing the expense of $30, leaves a profit of $90 USD. However, if there is a sudden crash in demand and crude oil price falls below $30 USD, then there is a real problem because an economy dependent on crude oil as major earner will be bankrupt immediately.
Suffice it to say now that, as at the time of this writing, oil prices have dropped by at least over 55%, thereby jettisoning Nigeria’s National income by over 75%, this comes as no surprise, since its sole product dependence for national income is crude oil. In other words, this practice adversely affects Nigeria’s Gross Domestic Product (GDP) & Gross National Product (GNP) and spiking high Interest rate, which inflates production costs and eventually consumer goods and services.
With the very common occurrence of public fund theft and diversion that has rocked Nigeria for over 30 years, Nigeria is quite in-equipped to face recession, stabilize and quickly make economic recovery. This puts public resources and services at a complete risk, with central Governments at the brink of inability to pay worker’s salaries or wages, alarming youths without means of livelihood. Nigeria’s current National foreign reserve is estimated to be over $30 billion USD. Other oil producing countries in the World such as Algeria, Tunisia, Libya, and Saudi Arabia are examples of countries that are effectively managing their crude oil earnings while it lasts.
In summary of this literature review, there is need for Nigeria to:
- Extremely diversify its source for foreign exchange reserve, so when an unexpected recession hits, the reserves can salvage its citizens from untold hardship or transference to other countries who definitely have theirs to carry and
- Save for the rainy day.
Now, let’s do word to vector analytics (deep learning) of documented reports historical facts (which we used for this literature review) from 1972 to 2018 regarding Nigeria’s local currency:
Fig. 2 Word to Vector Analysis, (Deep Learning) of Historical Literature on Nigerian Naira
Here, we see some major keywords that has played significantly in the embattled Naira:
“Nigeria’s President”, “Governor”, “Naira exchange”, “oil”, “foreign reserve”, “debt”, “1993”, “1998”, “1999”, “2004”, “2008”, and “2014”.
Obviously, the years 1993, 1998, 1999, 2004, 2008, and 2014, were remarkable years for Nigeria’s local currency. Particularly, years 1993, 1999, 2008 and 2014.
|1992/1993||Naira depreciates to 17 naira per dollar, goes further down to 22 per dollar afterwards|
|1999||Naira depreciates to 100 naira per dollar due to years of poor wealth mis-management.|
|2008||President Olusegun Obasanjo (II Term)
Chukwuma Soludo (2004-2009) Tenures with landmark changes to Nigeria’s Banking Sector, yet Naira depreciates further on exit
|2014||Nigeria enters JP Morgan, further depreciation of the Naira|
If there is anything to be learnt, these years and the events surrounding them should be revisited as source of enlightenment. In addition, Nigerian Presidents, the Governor of Central Bank of Nigeria seem to have played and will still play a major role in totally recovering Nigeria’s economic potential. Perhaps for the fact that they hold actionable policies that would have a positive or adverse impact on both the economy and the Nigerian people.
Artificial Intelligence, Machine (Deep Learning) Methodology in solving Economic Crisis in Nigeria
Machine (Deep Learning) an arm of Artificial Intelligence, is an active area of Computer science today and is currently serving as real time solutions to Health Research and Diagnostics, Fraud Detection, Pattern recognition amongst several other applications.
Fig. 3 , Support vector regression theoretical model
Support Vector Model:
Support Vector Model Algorithm is best described as a machine learning algorithm applied in classification or regression problems. For instance, every data item in a dataset is plotted as a point in n-dimensional space (where n is the amount of features in the dataset), with the number of each feature as the identification of a specific coordinate, Classification is rolled out as a position for each representation in the dataset.
In addition, Support Vector Models are best fitted for small datasets because it brings out needed features needed to be seen for actionable insights.
Furthermore, this model is under supervised machine learning algorithm that can be applied for both classification and regression problems. Let’s look at a typical data item as a position in say p –dimensional area n (where p is the number of features available), with the number of every feature appearing on the plot of a particular coordinate, then proper classification can be done in order to uniquely see differences on the plot. Next, we take a look at Response plots, Predicted vs. Actual Plots and Residuals plot for Naira-per US Dollar against Dates, and Nigerian Naira Local Selling rates against major currencies of the World.
Fig. 4 Image: Depicting Projected Naira per US Dollar against years 1970 to 2020.
NB. Response plots usually displays regression model results. Notice the overlap between 1992 and year 2000. This conforms to the earlier established fact of the remarkable events as indicated previously.
Fig. 5 Image: Depicting Naira against the dollar on a Predicted vs. Actual plot.
Generally, Predicted vs. Actual plot evaluates model performance. It demystifies how well the regression model makes predictions for different response values. It should be noted here that a perfect regression model has a predicted response equal to the true response, thus all the points lie on a diagonal line. The vertical distance from the line to any point is the error of the prediction for that point. An excellent model might have small errors, thus making some points as predictions scattered near the line.
Fig. 6 Image: Depicting Residuals plot of Naira against the dollar.
Residuals Plot: Typically assesses model performance. A perfect model has points or observations littered approximately and evenly distributed around 0.
Finally, as a wrap, let’s take a look at performance of the Naira against major World Currencies using linear regression model algorithm in Machine Learning.
Fig. 7  General Linear regression equation.
Categorically, we are evaluating recent performance of Nigerian Naira against CFA, Danish Krona, Euro, Pounds Sterling, Riyal, SDR, South African Rand, Swiss Franc, US Dollar, Waua, Yen, Yuan, and Reminbi, as evidenced from open datasets made available from Central Bank of Nigeria official website as reflected on the 14th of April, 2018. The major response variable here is the selling rate. This is logical since it is the selling that occasions buying.
Fig. 8 Image: Response plot of Naira against World Major Currencies.
Fig. 9 Image: Still within the response plot (Box Plot showing 25th and 75th percentiles) we see a prediction of naira depreciating against CFA, Danish Krona, Euro, Pounds Sterling, Riyal, SDR, Swiss Franc, USD, Waua, Yen, and Yuan/Renminbi, with respect to previous datasets up to and possibly beyond 2020.
Fig. 10 Image showing Predicted vs. Actual Plot of the NAIRA against World’s major currencies. Observe that we got similar results when comparing the Naira exchange rate to the dollar exclusively.
Fig. 11 Image showing Residuals plot of the Naira against World’s major currencies.
Results, Discussions & Conclusion
Except something is urgently done, Nigerian Naira faces a huge gloomy future up until 2020 and maybe beyond. Purchasing power will drop, cost of living will rise, standard of living which is already at all-time low will further plummet. With minimum wage less than $100 USD, and an exponential population growth on yearly basis, the successive Nigerian Governments (State and Federal) need to put aside, all distractions and make the country economically, academically, and socially strong, self sufficient to support its younger generation and scale beyond current limitations.
It is also very pertinent to mention here of the need to revisit those years that made landmark changes to the value of Nigeria’s National currency.
Redundant imports need to be halted at all costs, especially food and clothing, consumer goods that can be produced in house. If possible, blue-chip companies that produce cars, electronics should be localized or brought in for local production.
Stability, economic prosperity, and political stability in Nigeria plays an integral role in maintaining peace and progress not just in West Africa Sub region, (where it has played responsible leadership roles for over twenty years) but the African continent at large.
Nigerians also need to change their attitude to things, stop being stereotyped, pushing blames, or being complacent, or unable to take clear cut responsibility on economic matters since this affects virtually every facet of their livelihood. Other World countries work hard to make sure they are economically strong because the potential is there. A strong National currency will ensure affordable health, education, and infrastructure, better purchasing power for Nigerians both in business and on paid jobs. Especially for the fact that there is a yearly exponential population growth on annual basis thereby straining existing resources.
If Health, Education and Infrastructural development has to be secured for the Country, and its future generation, then Accountability, rich, diverse and sustained foreign exchange earning methods need to be developed and maintained. Nigeria’s economic turmoil has had a great history and impact indeed. The reason why her citizens keep attempting dangerous voyages through the Mediterranean to Europe is directly linked to harsh economic conditions in the country. Not to mention violent militancy by aggrieved parties in different parts of the country.
Therefore, for these to stop, there has to be serious, concerted efforts from all stakeholders, with all hands on deck to place this country back on track.
 Central Bank of Nigeria, April 2018. Central Bank of Nigeria Exchange Archives. [ONLINE] Available at: http://www.cbn.gov.ng/rates/ExchangeArchives.asp, [Accessed 14th April, 2018].
 A Gentle Introduction to Support Vector Machines, Teresa Powley [ONLINE] Available at: http://slideplayer.com/slide/1579281/, [Accessed 15th April, 2018].
 Dr. Asims Anatomy Cafe, Dr. Asims [ONLINE] Available at: http://www.dr-asims-anatomy-cafe.com/wp-content/uploads/2015/12/, [Accessed 15th April, 2018].
Many thanks to Adekunle Adebesho a Chartered Accountant, and Head of Unit, Revenue Office, Lagos State University, Ojo. Lagos for encouraging this concept.