Anton From Perm

Just another weblog

Doing Business in Russia

with 2 comments

The World Bank published a Doing Business in Russia report several weeks ago. It focuses on 4 main indicators: starting a business, getting a construction permit (which is a total nightmare in Russia 🙂 ), registering property and trading across borders. Each indicators is measured by the number of steps/documents, the time to complete the procedures and the costs as a percentage of national income. Strangely, the World Bank didn’t publish a simulator as it did for other countries (China, Mexico, etc…) Get the simulator as a Excel spreadsheet here (I use exactly the same methodology and formulas as the World Bank does in other reports)

A few words about the methodology:

The index is calculated as the simple average of a city’s percentile ranking on each of the 4 topics covered in the study (starting a business, getting a construction permit, registering property & trading abroad). The ranking on each topic is in turn the simple average of the percentile ranking on its component indicators. [The percentile rank is the percentage of values below (<) OR less or equal  (<=) to a  given value, depending on the definition]

For example it takes in Moscow 9 procedures, 30 days and 2.7% of annual income per capita to open a business.  The minimum capital requirement amounts to 2.2% of annual income per capita. It means that on the 4 component indicators, Moscow ranks in the 0th (best), 67th, 100th (worst) and 0th percentile. On average, Moscow ranks in the 53th percentile. It ranks in the 96th percentile on dealing with construction permits, 44th percentile on registering property and 67th percentile on trading across borders. The average of Moscow’s percentile rankings is 62%. If you now order all cities by their (ascending) average percentile rank, Moscow gets the last (and 10th) place.

However, percentiles are totally meaningless in small samples, especially when the observations are about the same and you get “tied ranks” while ordering the data. When you have ten values, of which eight are the same, you might have to assign the 0th or 100th percentile to the highest respectively the lowest value (some statisticians argues that the 0th and 100th percentile cannot be determined in a finite sample). And the remaining ones could lie in a range from 20th to 80th percentile (depending on HOW you define the percentile rank).

Now comes the problem: my calculations and the World Bank report’s result do not match, despite using exactly the same data and method. Let’s assume (out of goodwill) that the WB used a different method for calculating percentiles. I will post an update as soon as I get an answer from them.


Written by antonfromperm

December 3, 2009 at 3:27 pm

Ignorance & swine flu hype

leave a comment »

From ChartPorn:

Swine flu death toll as of 17. November 2009

While the CDC is brainwashing everyone to get swine flu vaccine (death toll < 9’000), over 48 millions people died of other causes during the same time. And no one (at least in the press) seem to care about them.


Written by antonfromperm

November 28, 2009 at 2:33 pm

Posted in Ignorance

Tagged with ,

McDonald’s expansion in Russia

leave a comment »

The Russian fastfood chain market is still considerated underpenetrated. McDonald’s (over 40 new outlets this year),  and Subway (> 900 new outlets by 2015) are progressing their expansion in Russia, while Burger King is opening its first outlet in Moscow this year.

The most interesting part is that MacDonald’s is very fond of its McDrive service, which apparently accounts for a huge chunck of its revenue in Russia. Taking the example of Kazan on this map, McDrives are even being opened in the very city centre (as opposed to the one/two floor counter service in most European cities).

Written by antonfromperm

November 27, 2009 at 3:09 pm

Posted in Uncategorized

Tagged with , ,

Russian Regions GRP 2008

with 4 comments

It is always easier to compare one thing with another, than to use numbers that no one can start something with. A map with US states renamed as if they were countries with similar GDP is available on StrangeMaps.

In the table below, the Russian GDP is broken down into the twenty biggest regions in terms of GRP (all together, they account for over 70% of the total Russian GRP), and their GRP is compared to other countries’ GDP.

Region GRP (mln USD) Comparable country
1. Moscow 343,334 Denmark
2. Khanty-Mansi Autonomous Okrug 73,440 Croatia
3. Moscow Oblast 68,108 Croatia
4. St. Petersburg 55,454 Luxenburg
5. Sverdlovsk Oblast 37,503 Guatemala
6. Republic of Tatarstan 37,420 Guatemala
7. Krasnodar Krai 33,610 Latvia
8. Republic of Bashkorstan 32,273 Uruguay
9. Krasnoyarsk Krai 30,782 Kenya
10. Yamalo-Nenets Autonomous Okrug 29,221 Costa Rica
11. Samara Oblast 28,401 Lebanon
12. Chelyabinsk Oblast 26,959 Burma, Yemen
13. Perm Krai 24,781 Cyprus
14. Nizhny Novgorod Oblast 23,848 Estonia
15. Rostov Oblast 23,680 Estonia
16. Kemerovo Oblast 23,663 Estonia
17. Orenburg Oblast 19,068 Bosnia
18. Irkutsk Oblast 18,824 Bosnia
19. Novosibirsk Oblast 17,463 Iceland
20. Volgograd Oblast 16,649 Paraguay

Please note that the figures are estimates from the Ministry of Regional Development, since the Federal State Statistics Service will publish the official figures only in May 2010… (BTW, today they finally learned to publish data in Excel files instead of HTML tables….)

EDIT: Khanty-Mansi & Yamalo Nenets Autonomnous Okrugs are not counted towards Tyumen’s GRP, but separately.

EDIT2: Tyumen’s GRP (without the autonomnous okrugs) dropped sharply in 2008 according to the estimates

Written by antonfromperm

November 26, 2009 at 2:29 pm

How to make a Russian regional thematic map

with 5 comments

Nathan at Flowing Data explained how to create a US County thematic map using free tools and it immensely helped me doing the same for Russian regions.

The Result

Inward FDI Performance Index 2005-2007

Step 1: Get the blank map

Unfortunately, we can’t take the blank Russia SVG map from Wikimedia Commons. First, it doesn’t take into account the latest mergers in 2008 (Irkutsk Oblast + Ust-Orda Buryat Autonomnous Okrug = Irkutsk Oblast, Chita Oblast + Agin-Buryat Autonomous Okrug = Zabaykalsky Krai). Second, the regions aren’t identified in the SVG file by their ISO_3166-2:RU code, but by their concatenated transliterated names. Third, the Federal Service of State Statistics doesn’t publish figures of several regions (like Yamalo-Nenets Autonomnous Okrug) because they fall under the administrative jurisdiction of other federal subjects of Russia (in this case Tyumen Oblast). It means that we have to group these regions together so that they can “inherit” the data visualization from their respective jurisdiction.

Get the new map I just uploaded to Wikimedia Commons here.

Step 2: Run python script

You can simply follow Nathan’s blog post and write it yourself, or use mine instead. I wrote it because I am too lazy to rewrite the script each time I want to colorize a map with different parameters.

Get it here (don’t forget to get BeautifulSoup first),:

Sample usage: python -d Inward_FDI_Performance_Index_2005_2007.csv -c RdYlBu6.dat -l IFPI.dat -i Russia2009blank.svg -o IFPI.svg


  • -d : Region specific data. Remove the headers and save it as a CSV file. Put the ISO3166-2:RU code into the first column, and the value into the second column
  • -c: Color scheme. It’s a simple text file containing the hexadecimal colors in reverse order, e.g. #D73027 #FC8D59 #FEE090 #E0F3F8 #91BFDB #4575B4
    Use ColorBrewer to help you select the colors to use.
  • -l: Legend file, e.g. 1 0.5 0.25 0.10 0 -0.1 The script will assign the last color in your list if the data point is above the first value in your legend file, and so on
  • -i: Input SVG file, i.e. the blank map
  • -o: Output SVG file


Written by antonfromperm

November 25, 2009 at 12:02 am

Easily unpivot data using Python

with one comment

Denormalized data in multiple columns

I was looking for an easy way to unpivot data, i.e. expand values from multiple columns in a single record into multiple records with the same values in a single column.

Normalized data in multiple records

Since the only tool available was SQL Server/SSIS, I wrote a short script in python (less than 50 lines of code) to easily unpivot CSV data.

Get the code here:


  • -v Verbose
  • -i Input file
  • -o Output file
  • -c Number of columns to be “frozen”, the default is one

Sample usage:
python -v -i GRP.csv -o GRPunpivot.csv -c 1

Written by antonfromperm

November 23, 2009 at 11:16 pm