Skip to content

Instantly share code, notes, and snippets.

@LTymn
Last active August 29, 2015 14:17
Show Gist options
  • Select an option

  • Save LTymn/cf09714939d5b3ebe48c to your computer and use it in GitHub Desktop.

Select an option

Save LTymn/cf09714939d5b3ebe48c to your computer and use it in GitHub Desktop.
Countries Module 2
Country Area(sq km) Birth rate(births/1000 population) Death rate(deaths/1000 population) HIV/AIDS - adult prevalence rate(%) HIV/AIDS - deaths Infant mortality rate(deaths/1000 live births) Life expectancy at birth(years) Population Total fertility rate(children born/woman) Unemployment rate(%)
Somalia 637657.00 45.62 16.97 1.00 0.00 116.70 48.09 8591629.00 6.84 0.00
Afghanistan 647500.00 47.02 20.75 0.01 0.00 163.07 42.90 29928987.00 6.75 0.00
Niger 1267000.00 48.30 21.33 1.20 4800.00 121.69 42.13 11665937.00 6.75 0.00
Uganda 236040.00 47.39 12.80 4.10 78000.00 67.83 51.59 27269482.00 6.74 0.00
Yemen 527970.00 43.07 8.53 0.10 0.00 61.50 61.75 20727063.00 6.67 35.00
Congo Democratic Republic of the 2345410.00 44.38 14.43 4.20 100000.00 92.87 49.35 60085804.00 6.54 0.00
Mali 1240000.00 46.77 19.05 1.90 12000.00 116.79 45.09 12291529.00 6.50 5.30
Malawi 118480.00 43.95 23.39 14.20 84000.00 103.32 36.97 12158924.00 5.98 0.00
Gaza Strip 360.00 40.03 3.87 0.00 0.00 22.93 71.79 1376289.00 5.91 50.00
Oman 212460.00 36.73 3.86 0.10 200.00 19.51 73.13 3001583.00 5.84 15.00
Burundi 27830.00 39.66 17.43 6.00 25000.00 69.29 43.50 6370609.00 5.81 0.00
Madagascar 587040.00 41.66 11.35 1.70 7500.00 76.83 56.95 18040341.00 5.66 0.00
Nigeria 923768.00 40.65 17.18 5.40 310000.00 98.80 46.74 128771988.00 5.53 0.00
Zambia 752614.00 41.38 20.23 16.50 89000.00 88.29 39.70 11261795.00 5.47 50.00
Gambia The 11300.00 39.86 11.81 1.20 600.00 72.02 55.20 1593256.00 5.38 0.00
Ethiopia 1127127.00 38.61 15.06 4.40 120000.00 95.32 48.83 73053286.00 5.33 0.00
Comoros 2170.00 37.52 8.40 0.12 0.00 74.93 61.96 671247.00 5.09 20.00
Haiti 27750.00 36.59 12.34 5.60 24000.00 73.45 52.92 8121622.00 5.02 0.00
Maldives 300.00 35.43 7.24 0.10 0.00 56.52 64.06 349106.00 5.02 0.00
Kenya 582650.00 40.13 14.65 6.70 150000.00 61.47 47.99 33829590.00 4.96 40.00
Sudan 2505810.00 35.17 9.16 2.30 23000.00 62.50 58.54 40187486.00 4.85 18.70
Laos 236800.00 35.99 11.83 0.10 200.00 85.22 55.08 6217141.00 4.77 5.70
Senegal 196190.00 35.21 10.60 0.80 3500.00 55.51 56.75 11126832.00 4.75 48.00
Mozambique 801590.00 35.79 20.99 12.20 110000.00 130.79 40.32 19406703.00 4.70 21.00
Guatemala 108890.00 34.11 6.81 1.10 5800.00 35.93 65.14 14655189.00 4.53 7.50
Central African Republic 622984.00 35.17 20.27 13.50 23000.00 91.00 41.01 3799897.00 4.50 8.00
Cameroon 475440.00 34.67 15.40 6.90 49000.00 68.26 47.84 16380005.00 4.47 30.00
West Bank 5860.00 32.37 3.99 0.00 0.00 19.62 73.08 2385615.00 4.40 27.20
Iraq 437072.00 32.50 5.49 0.10 0.00 50.25 68.70 26074906.00 4.28 25.00
Pakistan 803940.00 30.42 8.45 0.10 4900.00 72.44 63.00 162419946.00 4.14 8.30
Saudi Arabia 1960582.00 29.56 2.62 0.01 0.00 13.24 75.46 26417599.00 4.05 25.00
Paraguay 406750.00 29.43 4.53 0.50 600.00 25.63 74.89 6347884.00 3.93 15.10
Honduras 112090.00 30.38 6.87 1.80 4100.00 29.32 65.60 6975204.00 3.87 28.50
Zimbabwe 390580.00 29.74 24.66 24.60 170000.00 67.69 36.67 12746990.00 3.54 70.00
Syria 185180.00 28.29 4.88 0.10 200.00 29.53 70.03 18448752.00 3.50 20.00
Turkmenistan 488100.00 27.68 8.78 0.10 100.00 73.08 61.39 4952081.00 3.41 60.00
Libya 1759540.00 26.82 3.48 0.30 0.00 24.60 76.50 5765563.00 3.34 30.00
American Samoa 199.00 23.13 3.33 0.00 0.00 9.27 75.84 57881.00 3.25 6.00
Namibia 825418.00 25.16 18.36 21.30 16000.00 48.98 43.93 2030692.00 3.18 35.00
El Salvador 21040.00 27.04 5.85 0.70 2200.00 25.10 71.22 6704932.00 3.16 6.30
Philippines 300000.00 25.31 5.47 0.10 500.00 23.51 69.91 87857473.00 3.16 11.70
Turks and Caicos Islands 430.00 22.23 4.28 0.00 0.00 15.67 74.51 20556.00 3.08 10.00
Malaysia 329750.00 23.07 5.06 0.40 2000.00 17.70 72.24 23953136.00 3.07 3.00
Tonga 748.00 25.18 5.35 0.00 0.00 12.62 69.53 112422.00 3.00 13.30
Kuwait 17820.00 21.88 2.42 0.12 0.00 9.95 77.03 2335648.00 2.97 2.20
United Arab Emirates 82880.00 18.78 4.26 0.18 0.00 14.51 75.24 2563212.00 2.94 2.40
Egypt 1001450.00 23.32 5.26 0.10 700.00 32.59 71.00 77505756.00 2.88 10.90
Dominican Republic 48730.00 23.28 7.35 1.70 7900.00 32.38 67.26 8950034.00 2.86 17.00
India 3287590.00 22.32 8.28 0.90 310000.00 56.29 64.35 1080264388.00 2.78 9.20
Fiji 18270.00 22.73 5.65 0.10 200.00 12.62 69.53 893354.00 2.75 7.60
Morocco 446550.00 22.29 5.64 0.10 0.00 41.62 70.66 32725847.00 2.73 12.10
Ecuador 283560.00 22.67 4.24 0.30 1700.00 23.66 76.21 13363593.00 2.72 11.10
Jordan 92300.00 21.76 2.63 0.10 500.00 17.35 78.24 5759732.00 2.71 15.00
Kyrgyzstan 198500.00 22.48 7.13 0.10 200.00 35.64 68.16 5146281.00 2.70 18.00
Bahrain 665.00 18.10 4.08 0.20 200.00 17.27 74.23 688345.00 2.63 15.00
Peru 1285220.00 20.87 6.26 0.50 4200.00 31.94 69.53 27925628.00 2.56 9.60
Mexico 1972550.00 21.01 4.73 0.30 5000.00 20.91 75.19 106202903.00 2.45 3.20
Panama 78200.00 19.96 6.54 0.90 0.00 20.47 71.94 3039150.00 2.45 12.60
Indonesia 1919440.00 20.71 6.25 0.10 2400.00 35.60 69.57 241973879.00 2.44 9.20
Israel 20770.00 18.21 6.18 0.10 100.00 7.03 79.32 6276883.00 2.44 10.70
Greenland 2166086.00 15.93 7.77 0.00 0.00 15.82 69.65 56375.00 2.41 10.00
Grenada 344.00 22.30 7.17 0.00 0.00 14.62 64.53 89502.00 2.37 12.50
Costa Rica 51100.00 18.60 4.33 0.60 900.00 9.95 76.84 4016173.00 2.28 6.60
Mongolia 1564116.00 21.52 7.03 0.10 200.00 53.79 64.52 2791272.00 2.26 6.70
Venezuela 912050.00 18.91 4.90 0.70 4100.00 22.20 74.31 25375281.00 2.26 17.10
South Africa 1219912.00 18.48 21.32 21.50 370000.00 61.81 43.27 44344136.00 2.24 26.20
Bahamas The 13940.00 17.87 8.97 3.00 200.00 25.21 65.54 301790.00 2.20 10.20
Korea North 120540.00 16.09 7.05 0.00 0.00 24.04 71.37 22912177.00 2.15 0.00
United States 9631418.00 14.14 8.25 0.60 14000.00 6.50 77.71 295734134.00 2.08 5.50
Chile 756950.00 15.44 5.76 0.30 1400.00 8.80 76.58 15980912.00 2.02 8.50
Burma 678500.00 18.11 12.15 1.20 20000.00 67.24 56.22 42909464.00 2.01 5.20
Dominica 754.00 15.73 6.81 0.00 0.00 14.15 74.65 69029.00 1.96 23.00
Mauritius 2040.00 15.62 6.83 0.10 100.00 15.03 72.38 1230602.00 1.96 10.80
Jamaica 10991.00 16.56 5.37 1.20 900.00 12.36 76.29 2731832.00 1.95 15.00
Turkey 780580.00 16.83 5.96 0.10 0.00 41.04 72.36 69660559.00 1.94 9.30
Vietnam 329560.00 17.07 6.20 0.40 9000.00 25.95 70.61 83535576.00 1.94 1.90
Brazil 8511965.00 16.83 6.15 0.70 15000.00 29.61 71.69 186112794.00 1.93 11.50
Algeria 2381740.00 17.13 4.60 0.10 500.00 31.00 73.00 32531853.00 1.92 25.40
Iceland 103000.00 13.73 6.68 0.20 100.00 3.31 80.19 296737.00 1.92 3.10
Lebanon 10400.00 18.88 6.24 0.10 200.00 24.52 72.63 3826018.00 1.92 18.00
Guadeloupe 1780.00 15.42 6.06 0.00 0.00 8.60 77.90 448713.00 1.91 27.80
Puerto Rico 9104.00 13.93 7.86 0.00 0.00 8.24 77.62 3916632.00 1.91 12.00
Uruguay 176220.00 14.09 9.06 0.30 500.00 11.95 76.13 3415920.00 1.91 13.00
Cayman Islands 262.00 12.92 4.81 0.00 0.00 8.19 79.95 44270.00 1.90 4.10
Bermuda 53.00 11.60 7.63 0.00 0.00 8.53 77.79 65365.00 1.89 5.00
Kazakhstan 2717300.00 15.78 9.46 0.20 200.00 29.21 66.55 15185844.00 1.89 8.00
Thailand 514000.00 15.70 7.02 1.50 58000.00 20.48 71.57 65444371.00 1.88 1.50
Ireland 70280.00 14.47 7.85 0.10 100.00 5.39 77.56 4015676.00 1.87 4.30
France 547030.00 12.15 9.08 0.40 1000.00 4.26 79.60 60656178.00 1.85 10.10
Sri Lanka 65610.00 15.63 6.49 0.10 200.00 14.35 73.17 20064776.00 1.85 7.80
Cyprus 9250.00 12.57 7.64 0.10 0.00 7.18 77.65 780133.00 1.83 3.20
Iran 1648000.00 16.83 5.55 0.10 800.00 41.58 69.96 68017860.00 1.82 11.20
Luxembourg 2586.00 12.06 8.41 0.20 100.00 4.81 78.74 468571.00 1.79 4.50
New Zealand 268680.00 13.90 7.53 0.10 200.00 5.85 78.66 4035461.00 1.79 4.20
Montserrat 102.00 17.56 7.17 0.00 0.00 7.35 78.71 9341.00 1.78 6.00
Norway 324220.00 11.67 9.45 0.10 100.00 3.70 79.40 4593041.00 1.78 4.30
Australia 7686850.00 12.26 7.44 0.10 0.00 4.69 80.39 20090437.00 1.76 5.10
Monaco 2.00 9.26 12.71 0.00 0.00 5.43 79.57 32409.00 1.76 22.00
Seychelles 455.00 16.22 6.34 0.00 0.00 15.53 71.82 81188.00 1.75 0.00
Trinidad and Tobago 5128.00 12.81 9.37 3.20 1900.00 24.31 68.91 1088644.00 1.75 10.40
Tunisia 163610.00 15.50 5.09 0.10 200.00 24.77 74.89 10074951.00 1.75 13.80
Denmark 43094.00 11.36 10.43 0.20 100.00 4.56 77.62 5432335.00 1.74 6.20
Finland 338145.00 10.50 9.79 0.10 100.00 3.57 78.35 5223442.00 1.73 8.90
British Virgin Islands 153.00 14.96 4.42 0.00 0.00 18.05 76.27 22643.00 1.72 3.00
Bosnia and Herzegovina 51129.00 12.49 8.44 0.10 100.00 21.05 72.85 4025476.00 1.71 44.00
Cuba 110860.00 12.03 7.19 0.10 200.00 6.33 77.23 11346670.00 1.66 2.50
Netherlands 41526.00 11.14 8.68 0.20 100.00 5.04 78.81 16407491.00 1.66 6.00
Sweden 449964.00 10.36 10.36 0.10 100.00 2.77 80.40 9001774.00 1.66 5.60
United Kingdom 244820.00 10.78 10.18 0.20 500.00 5.16 78.38 60441457.00 1.66 4.80
Gibraltar 7.00 10.87 9.18 0.00 0.00 5.13 79.67 27884.00 1.65 2.00
Belgium 30528.00 10.48 10.22 0.20 100.00 4.68 78.62 10364388.00 1.64 12.00
Jersey 116.00 9.66 9.19 0.00 0.00 5.24 79.24 90812.00 1.57 0.90
Taiwan 35980.00 12.64 6.38 0.00 0.00 6.40 77.26 22894384.00 1.57 4.50
Malta 316.00 10.17 8.00 0.20 100.00 3.89 78.86 398534.00 1.50 7.00
Portugal 92391.00 10.82 10.43 0.40 1000.00 5.05 77.53 10566212.00 1.47 6.50
Switzerland 41290.00 9.77 8.48 0.40 100.00 4.39 80.39 7489370.00 1.42 3.40
Georgia 69700.00 10.25 9.09 0.10 200.00 18.59 75.88 4677401.00 1.41 17.00
Ukraine 603700.00 10.49 16.42 1.40 20000.00 20.34 66.85 47425336.00 1.40 3.50
Belarus 207600.00 10.83 14.15 0.30 1000.00 13.37 68.72 10300483.00 1.39 2.00
Croatia 56542.00 9.57 11.38 0.10 10.00 6.84 74.45 4495904.00 1.39 13.80
Estonia 45226.00 9.91 13.21 1.10 200.00 7.87 71.77 1332893.00 1.39 9.60
Germany 357021.00 8.33 10.55 0.10 1000.00 4.16 78.65 82431390.00 1.39 10.60
Japan 377835.00 9.47 8.95 0.10 500.00 3.26 81.15 127417244.00 1.39 4.70
Poland 312685.00 10.78 10.01 0.10 100.00 8.51 74.41 38635144.00 1.39 19.50
Bulgaria 110910.00 9.66 14.26 0.10 100.00 20.55 72.03 7450349.00 1.38 12.70
Austria 83870.00 8.81 9.70 0.30 100.00 4.66 78.92 8184691.00 1.36 4.40
Romania 237500.00 10.70 11.74 0.10 350.00 26.43 71.35 22329977.00 1.36 6.30
Greece 131940.00 9.72 10.15 0.20 100.00 5.53 79.09 10668354.00 1.33 10.00
Hungary 93030.00 9.76 13.19 0.10 100.00 8.57 72.40 10006835.00 1.32 5.90
Slovakia 48845.00 10.62 9.43 0.10 100.00 7.41 74.50 5431363.00 1.32 13.10
Italy 301230.00 8.89 10.30 0.50 1000.00 5.94 79.68 58103033.00 1.28 8.60
Spain 504782.00 10.10 9.63 0.70 1000.00 4.42 79.52 40341462.00 1.28 10.40
Northern Mariana Islands 477.00 19.51 2.30 0.00 0.00 7.11 75.88 80362.00 1.27 0.00
Russia 17075200.00 9.80 14.52 1.10 9000.00 15.39 67.10 143420309.00 1.27 8.30
Korea South 98480.00 10.08 6.26 0.10 200.00 7.05 75.82 48422644.00 1.26 3.60
Latvia 64589.00 9.04 13.70 0.60 500.00 9.55 71.05 2290237.00 1.26 8.80
Slovenia 20273.00 8.95 10.22 0.10 100.00 4.45 76.14 2011070.00 1.24 6.40
Czech Republic 78866.00 9.07 10.54 0.10 10.00 3.93 76.02 10241138.00 1.20 10.60
Lithuania 65200.00 8.62 10.92 0.10 200.00 6.89 73.97 3596617.00 1.19 8.00
Singapore 693.00 9.49 4.16 0.20 200.00 2.29 81.62 4425720.00 1.05 3.40
Hong Kong 1092.00 7.23 5.98 0.10 200.00 2.97 81.39 6898686.00 0.91 6.70
Antarctica 14000000.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Loading CSV Data with D3</title>
<script type="text/javascript" src="http://d3js.org/d3.v3.js"></script>
</head>
<body>
<svg width="500" height="200">
<circle cx="200" cy="10" r="100" fill="yellow" />
<text x="308" y="100" fill="aqua" font-size="42" font-weight="bold" font-family="Helvetica">Tourism
</svg>
<p>Not much to see here; try looking in the console!</p>
<script type="text/javascript">
//Load in contents of CSV file
d3.csv("Countries3.csv", function(data) {
//Now CSV contents have been transformed into
//an array of JSON objects.
//Log 'data' to the console, for verification.
console.log(data);
});
</script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment