After a long weekend crisscrossing Lagos, Kaduna and Abuja to deliver our quarterly Business Data Analysis and In-depth Excel Training in Abuja, I rested today and decided to do an interesting data analysis task. 

Do a sentiment analysis on today's tweets about the President, Buhari.

It was a very interesting task. Made me get familiar with Python's Tweepy library. I got some help from Marco Bonzanini. You should check out his Mastering Social Media Mining with Python book.

Here is the breakdown of the steps in achieving the goal:

  1. Created the needed credentials to access Twitter API (it's at https://apps.twitter.com/app/new)
  2. Use Tweepy to search in realtime for tweets about Buhari
  3. Save the tweets as a JSON file
  4. Handle emoticons and strings peculiar to Twitter (like @, # and so on)
  5. Exclude stop words (words with no significant, for sentiment analysis, meaning) like to, be, is etc
  6. Apply Vader to each tweet text and calculate the entire tweet stream sentiment
  7. Apply Sentiwordnet, an alternative to Vader, to do the same stream sentiment analysis
Below are the screenshots of some of the steps.

Twitter developer setup

Twitter developer setup
Vader Sentiment Analysis results

Sentiwordnet sentiment analysis result
And the results?

Well let's just say if the tweets are a mirror of what people genuinely feel about President Buhari, he should be terribly worried. Most people were very emotional in their tweets about him and overwhelmingly negative.


Vader classified the tweet stream as 54.67% negative vs 17.76% positive and 27.57% neutral.


Sentiwordnet gave a more damning result: 92.06% negative vs 7.48% positive and 0.47% neutral.

Both Vader and Sentiwordnet are rule-based supervised classification algorithms. In a context like Nigeria where we have our own Naija words and peculiar word mix, machine learning algorithm, supervised or non-supervised, might be more reliable.

image: guardian.ng

I arrived Abuja Airport (Nnamdi Azikwe International Airport) on Thursday and departed Abuja Airport today. How was that possible? Isn't the airport closed?

This past Friday and Saturday were the dates for our quarterly Excel and Business Data Analysis training in Abuja. So I had to pack my bag and training materials on Thursday, and head to Abuja. I had booked a 9:00am flight to Kaduna as the Abuja Airport is closed for runway repairs. As expected, Air Peace was on time.

I got to Kaduna by 10:15am. And there the surprise came. At the arrival wing of the airport, there were airport officials directing us to free buses to Abuja. The Federal Government has provided buses to convey passengers freely from Kaduna to Abuja and vice-versa.

The only issue is that the buses will take you from Kaduna Airport straight to Abuja Airport, no stop along the way and accompanied by a Police escort van. Also they've been ordered to drive annoyingly slow.

In effect, I got to Abuja Airport on Thursday.

After the training class on Friday and Saturday, I had to catch my return flight today in Kaduna. I took a cab to Abuja Airport, went to the departure wing and just as if I was going to board a plane, my luggage was scanned. Only different bit was there were no airline ticketing stands but a bus stand where you write your name and flight details and are then directed to board the next available bus to Kaduna. Again, free of charge. With escort and driving at a speed that makes the two hours journey three hours.

The buses are from Chisco Transport Company. And they were just as comfortable as having a plane ride, if you ignore the speed which must have been a government directive. It made it obvious that our Igbo brothers are business geniuses.



I would want to encourage anyone wanting to buy a new car to check out Innoson. I am not saying this to give an emotional support for "Made In Nigeria" but because I have seen the high quality, almost non-Nigerian like, products/services our Igbo brothers create when they put their industrious mind to it.



image: mildredwarner.org

I spent a good part of Wednesday reading Development Economics by Professor Debraj Ray. Debraj Ray is one of the few scholars focusing on development economics. And development economics is the aspect of economics that analyses how developing countries are different and how they can achieve sustainable economic development that will catapult them into the developed countries category.



His book was a huge eye opening for me on why Nigeria is where it is today and what are the most important issues for us to tackle if we want to transition from a low-income developing country into a high-income developed country status.

He carefully explained that the biggest problems developing countries have are weak systems -- political, market and infrastructural. That this lack of systems set off a vicious cycle that create inefficiencies and a wide gap between the have's and have not's.

That the absence of a strong independent legal system put justice out of reach of the common man and undermines the police system. People would rather sort out their issues in crude ways than let the police and legal systems be involved.

That the absence of credit markets, developed insurance markets and commodity markets create an inefficient agricultural sector where there is a very wide gap between what farmers make and what consumers pay at the final consumption end. This limits the transitioning of the subsistence farmer to a bigger and mechanized farmer as he is left with barely enough profit to cater for his family let alone acquire more land and high-tech equipment.

And the pattern continues through the health sector, financial sector, education sector and other critical sectors of the economy.

Without strong systems developing nations get stuck.

Culled from: http://registration.global-solutions.international/scholarship/scholarship-application

Apply at: http://registration.global-solutions.international/scholarship/scholarship-application

Application for the Young Global Changers Scholarship Programme


Are you an early-career researcher, entrepreneur, technology expert or journalist passionate about changing the state of the world for the better? Have you already developed tools, insights or mechanisms that address global issues and help to improve people’s lives?
Then you might be a Young Global Changer – and this scholarship is just right for you! Come to Berlin from 28 – 31 May 2017, attend the Think 20 Summit GLOBAL SOLUTIONS and share your work, thoughts and ideas with great minds from think tanks, business, politics and civil society.
In order to be eligible, your focus of interest should fit into one or several of the overarching topics of the Think 20 Summit GLOBAL SOLUTIONS.

Benefits of the programme:

-    Travel to Berlin and attend the Think 20 Summit GLOBAL SOLUTIONS from 28 – 31 May 2017. Accommodation will be provided and scholarship holders will receive a lump-sum to cover travel expenses
-    Become part of the G20 process and engage in the development of powerful narratives for one or more of the GLOBAL SOLUTIONS of the Conference
-    Meet Nobel Laureates and pitch your ideas to world renowned thinkers
-    Take part in dedicated Young Global Changers events on 28 and 31 May 2017
-    Link up with outstanding Berlin-based initiatives, entrepreneurs and scientists on a guided tour through Berlin
-    Become part of an exclusive network of like-minded Young Global Changers and build long-lasting relationships
-    Get access to quality journalism and receive a free subscription to Berlins leading newspaper in either German or English

Is a Young Global Changers Scholarship right for me?

Applicants must fit the following profile:
-    Early-career researcher, entrepreneur, technology expert or journalist/blogger
-    Able to attend the Think 20 Summit GLOBAL SOLUTIONS and dedicated Young Global Changers activities from 28 – 31 May 2017
-    Working on an idea or a specific project that you believe can change the world – or at least parts of it
-    Able to pitch your idea or project (in English) to a high-level audience
-    Willing to actively engage in creating a sustainable narrative for one of the GLOBAL SOLUTIONS that will be developed during the Conference

How to apply:

-    Please fill in the application form below (in English) and upload your CV and a short project or research description of max. 350 words
-    Tell us how and why this idea, project or initiative contributes to a better world and which specific topic of the GLOBAL SOLUTIONS Conference it addresses
-    Tell us why you want to be a Young Global Changer
-    If you are applying for the journalist programme, please submit two work samples. If work samples are not available in English, please submit a brief abstract in English with corresponding links to the original source
R is, arguably, the world's most popular programming language for data analysis. It is an adaptation of S language developed by Bells Laboratories strictly for statistics and data analysis. S language became very popular and R grew out of it as the open-source implementation of S language in August 1993.

The popularity of R is due to its open-source nature and the huge community contributing packages to it that handle all types of common data analysis work. You can read more about R at http://www.r-project.org/ and a more detailed history of R at http://www.r-project.org/about.html

Python, on the other hand, is a general purpose programming language. It is used for all types of programming from building websites (web applications) to computer programs and data analysis. It was created by Guido van Rossum in 1991. It is also an open-source language, benefiting hugely from a large community actively contributing to it. You can read more about Python at https://www.python.org/about/ 


image: medium.com

R and Python are the two most popular languages for data analysis. And anyone serious in becoming a data scientist must be proficient in at least one of the two. I recommend that you have average knowledge in both and then become an expert in one.

Both languages have libraries. More often called packages in R. They are already built algorithms that help you achieve specific tasks. More like Excel formulas, though way more robust in nature. You load them into your R or Python work space and can access the functions they provide.

A common need you will encounter is creating graphs/charts. In R, the most commonly used package for that is ggplot2 and in Python you would use Matplotlib.

To start using R and Python, you will need to install them. 

For R, you can download R at https://cran.r-project.org/ and it is recommended to install RStudio to make using R enjoyable. RStudio is an IDE (integrated development environment) and can be installed at https://www.rstudio.com/  With those two installations, you are set to begin analysing data with R. And they work whether you have a Windows PC, or Mac or Linux.

For Python, it is recommended that you download Anaconda at https://www.continuum.io/downloads. It is regarded as the best distribution of Python for data analysis work. And as for an IDE to use, there is no obvious best as RStudio is for R. Some people are a die-hard fan of Jupyter Notebook (formerly IPython Notebook), luckily it comes pre-installed with Anaconda. Others love Spyder (again, comes pre-installed with Anaconda). And there is PyCharm, you will have to install that at https://www.jetbrains.com/pycharm/. For this training series, I will be using Rodeo downloadable at https://www.yhat.com/products/rodeo, it is an RStudio lookalike. That way you won't have to stress yourself too much in getting used to the IDEs. Once you become familiar with RStudio, you will become more comfortable with Rodeo and vice-versa.

In the next sections we will dig deeper into carrying out simple data analysis tasks in both R and Python.

If I was the photo type, I would be bombing you today with pictures of me as a guest lecturer at Lagos Business School, taking the Executive MBA students on ___ Wanna take a guess? Try your luck!

image: hotels.ng

I managed to go thoroughly out of scope of their syllabus for the module I guest lectured on, but they were roundly impressed and happy. They kept clapping for me after my session, I thought they were just been courteous. Then after another session with a separate batch, it became obvious that they were genuinely clapping in appreciation. My host had to make them stop clapping, and they resumed after a while.

It was a very pleasant experience for me. And they have requested I come back again and again. I will try to play hard to catch, learned that from the ladies. They were a very pleasant audience. Gave me attention like they paid me directly and needed value for their money ('cos that's usually why my training participants give me rapt attention).

I had better start pitching Harvard Business School for guest lecturing slot. What have I to lose? I might even gain a nice "get lost" reply. It will do me some good, too much praises isn't very good. One need to find some disappointment to balance it all.

You asked and I have delivered. And I want to say a big thanks to everyone who kept asking and nudging me do to this -- I am happy to say its done.

Everyday, it automatically updates with the close of trading day price (for now set to 12 midnight, will adjust to late afternoon). It also shows the historical price from as far back as year 2002. That is something you won't get on any other platform for free. And the best part is that it is very interactive, I built it more like I do dashboards for very high paying clients.

It also allows you to compare the important financial statement lines of the stocks you are interested in: from Revenue, Net Profit, Return on Equity, Return on Assets, Total Assets, Gross Margin, Cashflow from Operations, Cashflow from Financing, Cashflow from Investing, Net Cash Flow, Current Assets, Current Liabilities to Total Liabilities.
And all very visual.
It has a scroll bar that shows you the latest closing price of all the stocks.
At the backend, I have a program that populates an Azure SQL database table with the closing prices for the stocks. I already have a stockpile of the annual reports of the companies from as far back as 2001 (you can check them out and download for free at https://www.slideshare.net/olafusimichael/presentations). Each year, I update the financial statement metrics from the Income Statement, Balance Sheet and Cash Flow.

Important Notice

Due to the hard work involved, I only cover the most active stocks on the Nigerian Stock Exchange. If there is any you would like to see that isn't there, do let me know and I may include it. Also there is an error in the Total Assets and Total Equities line for a couple of the bank stocks, I am working on making the correction. Other than that, all is working great (hopefully) and I use it for my own stock analysis. And that is the big edge, it is like I am sharing my quantitative stock analysis model with you all for free and in a very beautiful (to see and use) dashboard.
There are no 2016 financial metrics in yet. I am still gathering all the 2016 annual reports. Some companies have made theirs available online in the last two weeks, some are yet to. Maybe I won't wait till I have them all before I start the financial metrics extraction. I have already gotten for GTBank, First Bank, Total Nigeria, Access Bank, Dangote Cement, Cadbury, PZ and a few other companies.
The whole set-up (programming, hosting, virtual machine, SQL server etc) costs me money and I often pay freelance finance analysts to help share the work of extracting the data from the PDF annual reports into our standardized model. One day, I will put a door that opens only to paid subscription in front of it. So enjoy while its free!


There is a lot of textbook arguments on Excel vs Python vs R. In fact, a few weeks back I used to be part of that argument. I took sides with Excel. And I had my solid reasons.

But now I don't take sides anymore. I focus on a bigger picture, a picture I became aware of only after I transitioned for reading textbooks and doing video tutorials on Python and R to carrying out live interesting projects with them.

In this webinar I will be sharing my experience on using them all and what practical insight you too need to have to move from those textbook arguments to seeing the big picture. And most importantly, I will be showing you that big picture.

You shouldn't miss this webinar.

Time: 3:00pm to 4:00pm
Date: Tuesday, 21 March 2017
Venue: YouTube Live

You should set it up in your calendar with reminders so you won't miss this special edition.

See you!
image: zinpropertysolutions.com
If you live in Nigeria and earn your income in Naira, one big enemy you have is inflation. What one million naira bought five years ago now sells for two million naira. But the same one million naira left in a regular Nigerian bank savings account for the last five years will be about 1,174,000 naira.

And it gets worse when you project this over 20 or 30 years. You retire and find that your retirement savings which is 20% of your salary all throughout your 35 years of active work is now not enough to enjoy a comfortable life after retirement. Inflation has laid its corrosive hands on it.



Nigeria Inflation Rate from 2007 to 2017 (source, Bloomberg)
It is against that backdrop of high inflation rate and almost forever weakening Naira that I have carefully thought out my investment strategy.

When I began my investment journey, I made the classic mistake of thinking that what applied in the US markets, upon which all the investment books I read were built on, directly applied to the Nigerian markets. I even took seriously Jim Cramer's advice, in Jim Cramer's Real Money: Sane Investing in an Insane World, on how to time the market by analysing trends and technical signals. I thoroughly enjoyed reading Phil Town's Rule #1. I read many other popular books on investing.


They gave me a lot of theoretical knowledge and real-world use cases but no practical result. I couldn't apply most of what I learned due to the under-developed nature of our financial markets and the huge information asymmetry. Ultimately, I had more losses than gain until I changed my perspective.


For a global investor, Nigeria is a frontier market. One you don't put all your investments in except you are a private equity fund manager with focus on frontier markets. And I have just as much return expectation from my investments as any global investor would. Why then should I put all my investment in the highly volatile Nigerian financial markets?


The moment I took on the perspective of a global investor, I began using an asset class investment strategy. I invest in US markets, hedging both my inflation and weakening Naira risks. I switch between stocks, bonds and Gold depending on which is relatively undervalued. Currently US stocks are overvalued and trading at historical high P/E ratios. Last year December, I moved out of US stocks into bonds and emerging market index fund. Some analysts say it is more advisable to move to Gold rather than bond as the US interest rate hikes will damage bonds. That would be valid if I was buying long term bonds.


Then I have the remainder of my investments in the Nigerian markets, between our stocks and the money market. Currently, I am 95% stocks versus 5% money market for that remainder. The reason is that stocks are hugely undervalued. I don't mind losing out of the high return rates on the money market, I will patiently wait for the rally in the stocks market.


And as per the stocks I am invested in, besides the money I have in ARM Discovery Fund which I opened in my early investing days and occasionally keep funding due to the better-than-peers returns they make, I am invested in three companies on the Nigerian stock exchange (NSE): Nestle, First Bank and Mobil. I avoid companies with low trading volumes or in the penny-stock category and focus on the market leaders in non-correlated industries.

Why Nestle?
Nestle has the best fundamentals of all the major manufacturing companies in Nigeria. 

Up until the FX issue affected its profit last year, it was the perfect company for a long term investor. Now it is highly priced (has one of the highest PE) but it is due to an exceptional issue so I am not perturbed. Also I have the institutional wind in my favour, going through all the foreign Exchange Traded Funds with investments in the NSE, the only companies I have seen them invest in besides the banks are Nigerian Breweries, Dangote Cement and Nestle.


Why Mobil?
The downstream oil sector has historically proven to be inflation proof and, more recently, recession proof. The industry has been growing with the increased economic activities (GDP) over the years. It is the only industry that didn't get bashed seriously by the NSE crash (2008 till now).

I had made up my mind to invest in the best in the industry. Two companies were heads and shoulders above the others: Total Nigeria and Mobil Nigeria. Total is bigger by revenue. I went with Mobil because Mobil had the best fundamentals. Best ROI and most efficient in the industry. It is the GTBank of the Oil industry. Luckily, NIPCO acquired it and lead to a good bump in its price. Now it may not be attractively priced compared to Total.


Why First Bank?
This was a tough investment choice. GTBank has all the fundamentals and investors' love. However, the things about the banking and finance industry is that total assets is the strongest metric. Not even profit. The industry is so regulated that there is very little creative exploits Nigerian banks are allowed to make. The biggest differentiator in the long-run is total assets available to play with. And First Bank is the biggest bank in Nigeria by assets.

Unfortunately, it seems most investors are not factoring that in and have greatly discounted the oil industry loan exposure of the bank and other recent happenings that are temporary to bring very low the bank's share price. I bought it mainly because it gives the most potential value among the big four banks. I avoid industry minor players.

image: britishcouncil.org
All culled from: https://www.britishcouncil.org/future-leaders-connect/about

Apply at: https://www.britishcouncil.org/future-leaders-connect/apply

Future Leaders Connect offers its members the opportunity to be part of a long-term worldwide network of emerging policy leaders. You will have the chance to discuss some of the biggest global policy issues in the Houses of Parliament in London, develop your leadership skills, learn from inspirational policy leaders and make positive policy change in your country and beyond.

CONNECT TO A RESIDENTIAL PROGRAMME OF LEARNING AND DEVELOPMENT

You will take part in a residential development programme over a number of days. Based at a world class dedicated residential leadership development and conference centre, The Møller Centre at Churchill College in Cambridge. Here you will enhance your existing leadership skills and learn policy making best practice. Working as an international group, together you will combine your individual expertise to collectively address some of the world’s greatest global challenges.
Additionally, during your stay in the UK, you will have the opportunity to meet and engage with UK Parliamentarians, visit world leading institutions and attend private meetings with inspiring leaders and policymakers.

CONNECT TO THE UK HOUSES OF PARLIAMENT 

Finally your visit will end with a one-day immersive conference in the UK Houses of Parliament themed Fast Forward: Preparing for the World Ahead of Us. The conference will be an interactive day of discussions and debates with UK Parliamentarians addressing some of the world’s most urgent issues.

CONNECT TO A LONG-TERM NETWORK OF EMERGING LEADERS FROM AROUND THE GLOBE

You will stay actively connected to the network once you return home, taking advantage of opportunities to further develop your skills and to share and learn from your peers across the global network.

BECOMING A MEMBER OF FUTURE LEADERS CONNECT

Why should you apply to become a member of the British Council’s Future Leaders Connect?
  • Become a member of a long-term network, connecting with other future leaders from across the world
  • Access to a nine day programme of leadership and policy skill development
  • Enhance your professional development
  • Opportunity to have your voice and ideas heard in the UK Houses of Parliament
  • Attend private meetings with some of the UK’s most senior leaders
  • Visit world famous leadership institutions
  • Learn from senior policy experts and campaigners
  • Access to future opportunities from the British Council
Each year we will recruit more members for Future Leaders Connect. In 2017 there are 50 spaces available. This year we will welcome applicants from the following countries; Egypt, India, Indonesia, Kenya, Mexico, Morocco, Nigeria, Pakistan, Tunisia, and the UK.
Although India and Egypt are taking part in the programme they are not taking part in the open call. Applications from these two countries may have a different eligibility criteria and application process.