Project Part 1

Mobile money dominance in Sub-Saharan Africa

  1. I downloaded Mobile money Accounts, 2006 to 2018 data from Our World in Data. I chose this data because I’m curious in our world’s technological adoption in Sub-Saharan Africa in comparision of the world over the last decade.

  2. This is the Link to the data.

  3. The following code chunk loads the package I will use to read in and prepare the data for analysis

  1. Read the data in
registered_mobile_money_accounts<- read_csv(here::here("_posts/2022-05-05-project-part-1/registered-mobile-money-accounts.csv"))
  1. Use glimpse to see the names and types of the columns
glimpse (registered_mobile_money_accounts)
Rows: 103
Columns: 4
$ Entity                             <chr> "East Asia and Pacific", ~
$ Code                               <chr> NA, NA, NA, NA, NA, NA, N~
$ Year                               <dbl> 2011, 2012, 2013, 2014, 2~
$ `Registered Mobile Money Accounts` <dbl> 16674768, 14188036, 15693~
 View(registered_mobile_money_accounts)
  1. Use output from glimpse (and View) to prepare the data for analysis
account  <- c("World (excluding Sub-Saharan Africa)",
             "Sub-Saharan Africa")
account_mobile  <- registered_mobile_money_accounts  %>%
  rename(account = 1, MobileMoneyAccounts = 4 ) %>% 
  filter(Year >= 2006, account %in% account)  %>% 
  select(account, Year, MobileMoneyAccounts)  %>%
  mutate(MobileMoneyAccounts = MobileMoneyAccounts * 1e-9)

account_mobile
# A tibble: 103 x 3
   account                Year MobileMoneyAccounts
   <chr>                 <dbl>               <dbl>
 1 East Asia and Pacific  2011              0.0167
 2 East Asia and Pacific  2012              0.0142
 3 East Asia and Pacific  2013              0.0157
 4 East Asia and Pacific  2014              0.0245
 5 East Asia and Pacific  2015              0.0318
 6 East Asia and Pacific  2016              0.0490
 7 East Asia and Pacific  2017              0.0685
 8 East Asia and Pacific  2018              0.0946
 9 Eastern Africa         2011              0.0398
10 Eastern Africa         2012              0.0570
# ... with 93 more rows

Check that the total for 2018 equals the total in the graph

account_mobile  %>% filter(Year == 2018)  %>% 
  summarise(total_emm = sum(MobileMoneyAccounts))
# A tibble: 1 x 1
  total_emm
      <dbl>
1      2.60

See how to change the width in the R Markdown Cookbook

Mobile money dominance in Sub-Saharan Africa

Write the data to file in the project directory

write_csv(account_mobile, file="registered_mobile_money_accounts")