Author Archives: Ivan Kuznetsov

Are People in Colder Countries Taller? in Julia

By: Ivan Kuznetsov

Re-posted from: https://www.ivankuznetsov.com/2016/10/are-people-in-colder-countries-taller-in-julia.html

 

Are people in colder countries taller?

Continuing to play with Julia and data visualizations. This time I decided to replicate a scatterplot created by Matt Stiles examining the relationship between a country’s average temperature and its male residents’ average height.

Data comes from WorldBank and NCD-RisC. The size of the bubbles is linearly proportional to country population. Color indicates new World Bank income categories.

People seem to indeed be taller in colder countries. It would be interesting to explore deeper the relationship between wealth and height, especially adding time dimension – are people growing taller as countries become wealthier?

 

Interactive plot is available on Plot.ly, so you can play with the data yourself.

View the code on Gist.

 

Share

Life Expectancy by Country

By: Ivan Kuznetsov

Re-posted from: https://www.ivankuznetsov.com/2016/08/life-expectancy-by-country.html

Life Expectancy by CountryI was inspired by Andrew Collier’s blog post Life Expectancy by Country where he illustrated how to create a bubble chart that compares female and male life expectancies for a number of countries based on the data scraped from Wikipedia using R and Plot.ly charts.

I decided to replicate these results using another popular language for technical computing – Julia.

Scraping Wikipedia in Julia proved to be less elegant, as it is missing a convenient package for ingesting tabular data from web pages into data frames, but otherwise it was a relatively simple task.

The dotted line in the chart corresponds to equal female and male life expectancy. The size of the bubbles is linearly proportional to country population.

Interactive plot is available on Plot.ly.

View the code on Gist.

 

Share