Introduction

The Forbes Top 2000 is a yearly listing of the worlds largest 2000 companies ranked with regard to assets, sales, profits and market value from a wide range of industries. This post will visualize data from the last 12 years.

Data used was obtained as 12 seperate .csv files from “https://data.world/aroissues/forbes-global-2000-2008-2019”. Click the code button to see the code used in combining and cleaning all 12 files into a final dataset.

filenames <- list.files("Files")
num_names <- str_extract_all(filenames,"\\d{4}")
output <- vector(mode = "list",length = length(filenames) )

#Read files and add to a single list
i = 1
for (i in 1:length(output)) {
    output[[i]] <- read_csv(filenames[[i]])
    output[[i]]$Year <- rep(num_names[[i]][2],times=nrow(output[[i]]))  
    i = i + 1
}
rm(filenames,num_names)
#Sales missing in 8:12, create NA rows for that
i = 8
for (i in 8:12) {
  output[[i]]$Sales <- rep(NA, times = nrow(output[[i]]))
}
#Reorder columns for uniformity
i = 1
for (i in 1:length(output)) {
  output[[i]] <- output[[i]] %>% 
    select(names(output[[1]]))
}
#Merge all members of the list into a single data frame
i = 1
final_file <- data.frame()
for (i in 1:length(output)) {
  final_file = rbind(final_file,output[[i]])
  i = i + 1
}
rm(output,i)
final_file <- final_file %>% 
  mutate(Industry = ifelse(Industry=="Regional Banks"|Industry=="Major Banks","Banking",Industry)) %>%  
  mutate(Company = ifelse(Company=="Google","Alphabet",Company)) %>%   
  mutate(Company = ifelse(Company=="Tesla Motors","Tesla",Company)) %>%   
  mutate(Company = ifelse(Company=="Amazon.com","Amazon",Company))   
knitr::kable(
  head(final_file,10)  ,
  caption = "The first 10 entries in the data set"
)  

#Add a continent column for african countries
Africa <- c("Algeria","Angola","Benin","Botswana","Burkina Faso","Burundi","Cabo Verde","Cameroon","Central African Republic (CAR)","Chad","Comoros","Congo, Democratic Republic of the","Congo, Republic of the","Cote d'Ivoire","Djibouti","Egypt","Equatorial Guinea","Eritrea","Swaziland","Ethiopia","Gabon","Gambia","Ghana","Guinea","Guinea-Bissau","Kenya","Lesotho","Liberia","Libya","Madagascar","Malawi","Mali","Mauritania","Mauritius","Morocco","Mozambique","Namibia","Niger","Nigeria","Rwanda","Sao Tome and Principe","Senegal","Seychelles","Sierra Leone","Somalia","South Africa","Sudan","South Sudan","Tanzania","Togo","Tunisia","Uganda","Zambia","Zimbabwe")

final_file <- final_file %>% 
  mutate(Continent = case_when(
    Country %in% Africa~"Africa",
    TRUE~"Others"))
rm(Africa)
The first 10 entries in the data set
Company Industry Country Market Value Profits Assets Sales Rank Year
HSBC Holdings Banking United Kingdom 180.81 19.13 2348.98 146.50 1 2008
General Electric Conglomerates United States 330.93 22.21 795.34 172.74 2 2008
Bank of America Banking United States 176.53 14.98 1715.75 119.19 3 2008
JPMorgan Chase Banking United States 136.88 15.37 1562.15 116.35 4 2008
ExxonMobil Oil & Gas Operations United States 465.51 40.61 242.08 358.60 5 2008
Royal Dutch Shell Oil & Gas Operations Netherlands 221.09 31.33 266.22 355.78 6 2008
BP Oil & Gas Operations United Kingdom 204.94 20.60 236.08 281.03 7 2008
Toyota Motor Consumer Durables Japan 175.08 13.99 276.38 203.80 8 2008
ING Group Insurance Netherlands 75.78 12.65 1932.15 197.93 9 2008
Berkshire Hathaway Diversified Financials United States 216.65 13.21 273.16 118.25 10 2008

Visualization


Top_10 <- final_file %>% 
  mutate(`Rank.`=11-Rank) %>%
  group_by(Year) %>% 
  top_n(10,desc(Rank)) %>% 
  ungroup() %>% 
  arrange(Year,Rank) %>% 
  mutate(order = row_number()) %>% 
  filter(Year>=2014)
  
  company <- reorder_within(Top_10$Company,Top_10$order,Top_10$Year)
  
  plot_1 <- ggplot(Top_10,aes(x=company,y=Rank))+
  geom_col(aes(fill=Country))+
  scale_x_reordered()+
  theme(axis.text.y=element_blank(),
        axis.ticks.y=element_blank(),
        axis.title.y=element_blank(),
        axis.text.x=element_text(angle = 45),
        axis.ticks.x=element_blank(),
        axis.title.x=element_blank(),
        panel.spacing.y = unit(6,"lines"),
        panel.spacing.x = unit(4,"lines")
        )+
  facet_wrap(~Year,scales = "free_x",ncol = 2)+
  #coord_flip()+
    labs(x="",y="")
  ggplotly(plot_1)

Chart 1: Top 10 Companies each year

The first set of charts show the top ten ranked corporations in the world over the last 6 years.

The Industrial and Commercial Bank of China,ICBC was the top ranked corporation for 6 years in a row. Apple made its debut on the top 10 list in 2016 and has remained the only tech company on the list since then.

Other notable corporations include Berkshire Hathaway owned by Warren Buffet and Wells Fargo.


Top_5_Industry <- final_file %>% 
    group_by(Year) %>% 
    count(Industry) %>%
    arrange(Year,desc(n)) %>% 
    mutate(`Proportion (%)` = round((n/sum(n))*100,2),
         cumprop = cumsum(`Proportion (%)`)) %>% 
    top_n(5,n) 

  plot_2 <- ggplot(Top_5_Industry,aes(Year,`Proportion (%)`))+
  geom_col(aes(fill=Industry))+
  labs(x="",y="")
  ggplotly(plot_2)

Chart 2: The 5 Largest industries each year

The second chart depicts the 5 most represented industries within the top 2000 companies each year. The banking industry has consistently remained the largest with about 15% of all corporations within the top 2000 coming from the banking sector each year.


Top_5_Country <- final_file %>%
  group_by(Year) %>% 
  count(Country) %>%
  arrange(Year,desc(n)) %>% 
  top_n(5,n) %>%
  mutate(`Proportion (%)` = round((n/sum(n))*100,2),
         cumprop = cumsum(`Proportion (%)`)
  ) 

plot_3 <- ggplot(Top_5_Country,aes(Year,`Proportion (%)`))+
  geom_line(aes(group=Country,color=Country),size=1)+
  geom_point(aes(group=Country,color=Country),size=3)+
  labs(x="",y="Proportion of Companies",subtitle = "Proportion of Companies from each country in the Top 2000")
 
 ggplotly(plot_3)

Chart 3: Top 5 Countries in the Top 2000

Our third chart visualizes the countries most frequently featured on the list. The United states alone is the home country for about half of the companies on the Top 2000 list each year.

About 25% of corporations are from Japan, although that has declined in recent years to about 1 in 5 corporations. China continues to experience increasing representation more than tripling its presence on the list over the 12 year period.

No African country has ever had more than 20 corporations on the list in any year.


dat_4 <- final_file %>%
    filter(Continent=="Africa") %>% 
    group_by(Year) %>% 
    count(Country) %>%
    arrange(Year,desc(n)) %>% 
    top_n(5,n) %>%
    mutate(prop = (n/sum(n))*100,
         cumprop = cumsum(prop)
  ) %>% 
   mutate(No.=n)
  plot_4 <- ggplot(dat_4, aes(Year,No.))+
  geom_line(aes(group=Country,color=Country),size=1)+
  geom_point(aes(group=Country,color=Country),size=3)+
  labs(x="",y="Number of Companies",subtitle = "Number of Companies from each country in the Top 2000")
  
  ggplotly(plot_4)

Chart 4: African countries in the Top 2000

The story is quite different for the african countries, South africa has been the most commonly featuring african country on the list over the last 12 years, and is the only african country to hit double digits, no other african country has had more than 5 companies on the list for any year.


dat_6 <- final_file %>% 
    filter(Country == "Nigeria") 
  
  plot_6 <- ggplot(dat_6,aes(Year,Rank))+
    geom_line(aes(group=Company,color=Company),size=1)+
    geom_point(aes(group=Company,color=Company),size=3)+
    scale_y_reverse()+
    labs()
  
  ggplotly(plot_6) 

Chart 5: Nigerian Companies in the Top 2000

This chart depicts the Nigerian companies that have made it to the top 2000 list over the last 12 years, Dangote Cement and Zenith bank PLC have been the most consistent Nigerian companies, both making their debut on the list in 2011 and 2010 respectively and staying on the list since. Dangote cement has also been the highest ranked Nigerian company since making its debut.


big_tech <- c("Apple","Samsung Electronics","Microsoft","Alphabet","Intel","IBM","Facebook","Tesla","Amazon","Oracle")
  dat_5 <- final_file %>% 
  filter(Company %in% big_tech) 
  
  plot_5 <- ggplot(dat_5,aes(Year,Rank))+
  geom_line(aes(group=Company,color=Company),size=1)+
  geom_point(aes(group=Company,color=Company),size=3)+
  scale_y_reverse()
  
  ggplotly(plot_5)  

Chart 6: The Top tech Companies

We also look at 10 of the “BIG” names in tech, most were clustered in the first 100, especially in recent years. Overall, Apple has consistently been the highest ranked of the lot, Facebook and Tesla were relatively late debutants on the list but have risen rapidly with Facebook going from the bottom half of the ranking to the top 100 in 7 years.

The legend icons are clickable and can be used to declutter the plot.