Difference between revisions of "Most active countries"

From Geohashing
(updating stats)
(updating stats)
Line 1: Line 1:
The following table shows countries by their number of reached and total expeditions as of 2021-09-26 00:08:39 UTC. __TOC__
+
The following table shows countries by their number of reached and total expeditions as of 2021-09-27 00:08:26 UTC. __TOC__
 
==Methodology and Limitations==
 
==Methodology and Limitations==
 
For the purpose of this list, a country is defined as anything that has a [[wikipedia:ISO 3166-1|ISO 3166-1]] code.
 
For the purpose of this list, a country is defined as anything that has a [[wikipedia:ISO 3166-1|ISO 3166-1]] code.
Line 16: Line 16:
 
|3||[[:Category:Expeditions in the United Kingdom|United Kingdom]]||1366||48||124||105||113||167||98||52||327||185||46||39||29||30||3
 
|3||[[:Category:Expeditions in the United Kingdom|United Kingdom]]||1366||48||124||105||113||167||98||52||327||185||46||39||29||30||3
 
|-
 
|-
|4||[[:Category:Expeditions in Australia|Australia]]||669||97||102||54||40||98||80||28||34||28||24||15||17||26||26
+
|4||[[:Category:Expeditions in Australia|Australia]]||670||97||102||54||40||98||80||28||34||28||24||15||17||26||27
 
|-
 
|-
 
|5||[[:Category:Expeditions in Finland|Finland]]||612||20||23||52||35||35||92||92||63||49||33||26||27||45||20
 
|5||[[:Category:Expeditions in Finland|Finland]]||612||20||23||52||35||35||92||92||63||49||33||26||27||45||20
Line 24: Line 24:
 
|7||[[:Category:Expeditions in Sweden|Sweden]]||414||26||49||60||77||118||25||14||8||5||4||1||8||13||6
 
|7||[[:Category:Expeditions in Sweden|Sweden]]||414||26||49||60||77||118||25||14||8||5||4||1||8||13||6
 
|-
 
|-
|8||[[:Category:Expeditions in the Netherlands|Netherlands]]||372||42||16||9||10||52||22||42||45||34||28||18||19||22||13
+
|8||[[:Category:Expeditions in the Netherlands|Netherlands]]||373||42||16||9||10||52||22||42||45||34||28||18||19||22||14
 
|-
 
|-
 
|9||[[:Category:Expeditions in Switzerland|Switzerland]]||231||6||16||14||32||41||55||14||12||11||3||2||1||18||6
 
|9||[[:Category:Expeditions in Switzerland|Switzerland]]||231||6||16||14||32||41||55||14||12||11||3||2||1||18||6
 
|-
 
|-
|10||[[:Category:Expeditions in France|France]]||172||8||18||7||11||15||14||14||3||6||10||2||7||24||33
+
|10||[[:Category:Expeditions in France|France]]||173||8||18||7||11||15||14||14||3||6||10||2||7||24||34
 
|-
 
|-
 
|11||[[:Category:Expeditions in New Zealand|New Zealand]]||149||18||7||28||16||12||5||15||16||8||7||10||3||3||1
 
|11||[[:Category:Expeditions in New Zealand|New Zealand]]||149||18||7||28||16||12||5||15||16||8||7||10||3||3||1
Line 162: Line 162:
 
|1||[[:Category:Expeditions in the United States of America|United States of America]]||3792||402||590||427||267||437||436||279||228||175||125||100||92||145||89
 
|1||[[:Category:Expeditions in the United States of America|United States of America]]||3792||402||590||427||267||437||436||279||228||175||125||100||92||145||89
 
|-
 
|-
|2||[[:Category:Expeditions in Germany|Germany]]||3609||155||447||240||293||275||251||353||331||218||166||200||228||237||215
+
|2||[[:Category:Expeditions in Germany|Germany]]||3610||155||447||240||293||275||251||353||331||218||166||200||228||237||216
 
|-
 
|-
 
|3||[[:Category:Expeditions in the United Kingdom|United Kingdom]]||1128||26||101||84||95||132||82||44||284||162||40||33||24||20||1
 
|3||[[:Category:Expeditions in the United Kingdom|United Kingdom]]||1128||26||101||84||95||132||82||44||284||162||40||33||24||20||1
Line 168: Line 168:
 
|4||[[:Category:Expeditions in Finland|Finland]]||574||16||20||49||32||31||82||87||62||49||33||26||26||43||18
 
|4||[[:Category:Expeditions in Finland|Finland]]||574||16||20||49||32||31||82||87||62||49||33||26||26||43||18
 
|-
 
|-
|5||[[:Category:Expeditions in Australia|Australia]]||501||77||69||45||35||54||59||21||25||23||20||11||15||24||23
+
|5||[[:Category:Expeditions in Australia|Australia]]||502||77||69||45||35||54||59||21||25||23||20||11||15||24||24
 
|-
 
|-
 
|6||[[:Category:Expeditions in Canada|Canada]]||380||61||76||81||47||29||20||14||7||5||9||12||4||11||4
 
|6||[[:Category:Expeditions in Canada|Canada]]||380||61||76||81||47||29||20||14||7||5||9||12||4||11||4
Line 174: Line 174:
 
|7||[[:Category:Expeditions in Sweden|Sweden]]||363||19||45||49||66||110||23||14||7||5||4||1||7||8||5
 
|7||[[:Category:Expeditions in Sweden|Sweden]]||363||19||45||49||66||110||23||14||7||5||4||1||7||8||5
 
|-
 
|-
|8||[[:Category:Expeditions in the Netherlands|Netherlands]]||295||31||13||6||6||43||19||33||34||25||24||16||15||19||11
+
|8||[[:Category:Expeditions in the Netherlands|Netherlands]]||296||31||13||6||6||43||19||33||34||25||24||16||15||19||12
 
|-
 
|-
 
|9||[[:Category:Expeditions in Switzerland|Switzerland]]||208||5||14||14||26||36||52||13||12||10||3||2||1||16||4
 
|9||[[:Category:Expeditions in Switzerland|Switzerland]]||208||5||14||14||26||36||52||13||12||10||3||2||1||16||4

Revision as of 00:09, 27 September 2021

The following table shows countries by their number of reached and total expeditions as of 2021-09-27 00:08:26 UTC.

Methodology and Limitations

For the purpose of this list, a country is defined as anything that has a ISO 3166-1 code.

This page is generated by looking where location templates are transcluded, and at the expeditions category and the coordinates reached category. This page is only as good as those categories.

Check out the program's source code.

Expeditions

# Country Σ 08 09 10 11 12 13 14 15 16 17 18 19 20 21
1 United States of America 5129 630 767 574 371 609 577 348 288 233 157 144 117 195 119
2 Germany 4098 186 509 283 333 314 290 410 368 248 186 219 257 254 241
3 United Kingdom 1366 48 124 105 113 167 98 52 327 185 46 39 29 30 3
4 Australia 670 97 102 54 40 98 80 28 34 28 24 15 17 26 27
5 Finland 612 20 23 52 35 35 92 92 63 49 33 26 27 45 20
6 Canada 524 91 120 107 56 36 29 20 11 6 10 12 5 16 5
7 Sweden 414 26 49 60 77 118 25 14 8 5 4 1 8 13 6
8 Netherlands 373 42 16 9 10 52 22 42 45 34 28 18 19 22 14
9 Switzerland 231 6 16 14 32 41 55 14 12 11 3 2 1 18 6
10 France 173 8 18 7 11 15 14 14 3 6 10 2 7 24 34
11 New Zealand 149 18 7 28 16 12 5 15 16 8 7 10 3 3 1
12 Poland 145 3 4 18 6 13 30 12 22 4 8 7 4 8 6
13 Austria 127 3 4 5 3 2 15 47 26 8 5 2 1 2 4
14 Russia 96 0 0 1 2 21 41 6 2 4 3 0 1 4 11
15 Norway 87 20 2 27 10 16 0 4 3 0 0 0 1 2 2
16 Spain 81 2 5 4 2 8 10 4 4 2 0 5 1 1 33
17 Israel 76 1 10 0 2 6 4 1 0 0 13 26 9 1 3
18 Italy 55 1 4 8 4 9 12 6 7 1 0 1 0 0 2
19 Czechia 53 5 7 6 5 8 4 4 13 0 0 1 0 0 0
20 Denmark 43 7 5 3 3 4 3 3 5 1 0 0 2 5 2
21 Belgium 40 6 5 4 3 9 3 2 2 1 2 2 0 1 0
22 Singapore 37 7 2 0 7 4 5 2 0 2 5 1 0 1 1
23 Argentina 29 0 0 0 0 2 2 3 17 3 1 1 0 0 0
24 Bulgaria 27 0 0 4 8 6 3 6 0 0 0 0 0 0 0
25 Hungary 23 9 1 0 0 0 2 2 5 3 0 0 1 0 0
26 Japan 16 0 6 4 0 5 0 0 1 0 0 0 0 0 0
27 Indonesia 15 0 3 0 1 1 1 2 1 4 1 0 1 0 0
28 Brazil 12 3 0 0 1 1 0 0 1 1 1 3 0 1 0
29 India 11 0 0 8 0 1 2 0 0 0 0 0 0 0 0
30 Ireland 10 0 4 1 2 2 1 0 0 0 0 0 0 0 0
31 Slovenia 9 2 1 1 1 2 0 1 0 1 0 0 0 0 0
32 Mexico 9 1 5 1 0 0 0 1 0 0 0 0 0 0 1
33 China 9 0 0 5 1 1 0 0 1 0 0 0 0 0 1
34 Slovakia 8 1 0 2 0 0 0 0 4 1 0 0 0 0 0
35 international waters 7 2 0 1 0 1 1 0 0 0 0 0 1 1 0
36 Ukraine 7 1 0 0 0 0 0 0 0 0 0 0 0 1 5
37 Greece 7 0 0 0 0 2 0 2 1 1 0 0 0 1 0
38 South Africa 6 0 2 0 1 1 0 0 0 0 0 2 0 0 0
39 Croatia 6 0 0 0 0 1 0 2 3 0 0 0 0 0 0
40 Turkey 5 0 3 1 0 0 0 0 0 0 0 1 0 0 0
41 Portugal 5 0 1 0 1 0 1 0 0 0 1 0 0 1 0
42 Nepal 5 0 0 3 2 0 0 0 0 0 0 0 0 0 0
43 Malaysia 4 0 0 1 0 2 0 0 0 0 1 0 0 0 0
44 Latvia 4 0 0 0 1 0 0 0 1 0 1 0 1 0 0
45 Romania 3 0 0 0 0 1 0 0 2 0 0 0 0 0 0
46 Philippines 3 0 0 0 0 0 0 2 0 0 1 0 0 0 0
47 Luxembourg 3 1 1 0 0 0 1 0 0 0 0 0 0 0 0
48 Estonia 3 0 1 1 0 0 0 0 0 0 1 0 0 0 0
49 Cyprus 3 0 0 0 1 1 0 0 0 0 0 1 0 0 0
50 Chile 3 2 1 0 0 0 0 0 0 0 0 0 0 0 0
51 Thailand 2 0 0 2 0 0 0 0 0 0 0 0 0 0 0
52 Malta 2 0 0 0 0 0 2 0 0 0 0 0 0 0 0
53 Lithuania 2 0 0 0 0 1 1 0 0 0 0 0 0 0 0
54 South Korea 2 0 1 0 0 0 0 1 0 0 0 0 0 0 0
55 Jersey 2 0 1 1 0 0 0 0 0 0 0 0 0 0 0
56 Iceland 2 0 0 0 0 0 1 0 0 1 0 0 0 0 0
57 Costa Rica 2 0 0 0 0 0 0 0 0 0 0 0 0 2 0
58 Uruguay 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0
59 Tunisia 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0
60 Tajikistan 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0
61 Svalbard and Jan Mayen 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0
62 Serbia 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0
63 Puerto Rico 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0
64 Peru 1 0 0 0 0 0 0 0 0 0 0 0 1 0 0
65 Namibia 1 0 0 0 0 0 0 0 0 0 0 0 0 1 0
66 Martinique 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0
67 Morocco 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0
68 Liechtenstein 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0
69 Cambodia 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0
70 Dominican Republic 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0
71 Cuba 1 0 0 0 0 0 0 0 0 1 0 0 0 0 0
72 Antarctica 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0
73 United Arab Emirates 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0

Coordinates reached

# Country Σ 08 09 10 11 12 13 14 15 16 17 18 19 20 21
1 United States of America 3792 402 590 427 267 437 436 279 228 175 125 100 92 145 89
2 Germany 3610 155 447 240 293 275 251 353 331 218 166 200 228 237 216
3 United Kingdom 1128 26 101 84 95 132 82 44 284 162 40 33 24 20 1
4 Finland 574 16 20 49 32 31 82 87 62 49 33 26 26 43 18
5 Australia 502 77 69 45 35 54 59 21 25 23 20 11 15 24 24
6 Canada 380 61 76 81 47 29 20 14 7 5 9 12 4 11 4
7 Sweden 363 19 45 49 66 110 23 14 7 5 4 1 7 8 5
8 Netherlands 296 31 13 6 6 43 19 33 34 25 24 16 15 19 12
9 Switzerland 208 5 14 14 26 36 52 13 12 10 3 2 1 16 4
10 France 143 6 14 5 8 13 11 12 3 5 7 2 5 22 30
11 New Zealand 128 13 7 24 12 10 3 14 16 8 5 9 3 3 1
12 Poland 125 2 3 14 6 11 24 11 20 4 7 6 4 8 5
13 Austria 111 2 3 4 3 0 14 45 20 8 5 2 1 1 3
14 Russia 77 0 0 1 1 19 33 5 2 3 1 0 1 4 7
15 Norway 67 13 1 19 8 15 0 4 3 0 0 0 0 2 2
16 Spain 65 1 5 3 2 7 7 4 4 2 0 4 1 0 25
17 Israel 61 0 5 0 1 5 4 1 0 0 11 23 8 1 2
18 Italy 46 1 4 5 4 7 9 6 7 1 0 1 0 0 1
19 Czechia 45 4 7 5 5 7 2 2 12 0 0 1 0 0 0
20 Denmark 33 4 4 2 2 3 3 3 4 1 0 0 2 3 2
21 Belgium 32 3 4 3 3 7 2 2 2 1 2 2 0 1 0
22 Singapore 27 3 1 0 5 3 4 2 0 2 4 1 0 1 1
23 Bulgaria 25 0 0 3 8 6 3 5 0 0 0 0 0 0 0
24 Argentina 24 0 0 0 0 1 1 3 14 3 1 1 0 0 0
25 Hungary 17 4 1 0 0 0 2 2 5 2 0 0 1 0 0
26 Japan 14 0 6 3 0 4 0 0 1 0 0 0 0 0 0
27 Indonesia 12 0 2 0 1 0 1 1 1 4 1 0 1 0 0
28 India 10 0 0 8 0 0 2 0 0 0 0 0 0 0 0
29 Brazil 9 3 0 0 1 0 0 0 1 1 1 2 0 0 0
30 Ireland 8 0 4 1 2 1 0 0 0 0 0 0 0 0 0
31 Slovakia 7 1 0 1 0 0 0 0 4 1 0 0 0 0 0
32 Slovenia 7 1 1 1 1 2 0 1 0 0 0 0 0 0 0
33 Ukraine 6 1 0 0 0 0 0 0 0 0 0 0 0 1 4
34 Mexico 6 1 3 1 0 0 0 0 0 0 0 0 0 0 1
35 China 6 0 0 4 0 1 0 0 0 0 0 0 0 0 1
36 South Africa 5 0 2 0 1 1 0 0 0 0 0 1 0 0 0
37 Greece 5 0 0 0 0 2 0 1 1 0 0 0 0 1 0
38 Portugal 4 0 1 0 1 0 1 0 0 0 1 0 0 0 0
39 Latvia 4 0 0 0 1 0 0 0 1 0 1 0 1 0 0
40 Croatia 4 0 0 0 0 0 0 1 3 0 0 0 0 0 0
41 Nepal 3 0 0 2 1 0 0 0 0 0 0 0 0 0 0
42 Malaysia 3 0 0 0 0 2 0 0 0 0 1 0 0 0 0
43 international waters 2 0 0 0 0 0 0 0 0 0 0 0 1 1 0
44 Romania 2 0 0 0 0 1 0 0 1 0 0 0 0 0 0
45 Philippines 2 0 0 0 0 0 0 1 0 0 1 0 0 0 0
46 Malta 2 0 0 0 0 0 2 0 0 0 0 0 0 0 0
47 Luxembourg 2 1 1 0 0 0 0 0 0 0 0 0 0 0 0
48 Jersey 2 0 1 1 0 0 0 0 0 0 0 0 0 0 0
49 Iceland 2 0 0 0 0 0 1 0 0 1 0 0 0 0 0
50 Estonia 2 0 0 1 0 0 0 0 0 0 1 0 0 0 0
51 Cyprus 2 0 0 0 1 1 0 0 0 0 0 0 0 0 0
52 Chile 2 1 1 0 0 0 0 0 0 0 0 0 0 0 0
53 Turkey 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0
54 Tunisia 1 0 0 0 0 0 0 0 1 0 0 0 0 0 0
55 Tajikistan 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0
56 Thailand 1 0 0 1 0 0 0 0 0 0 0 0 0 0 0
57 Svalbard and Jan Mayen 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0
58 Serbia 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0
59 Lithuania 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0
60 Liechtenstein 1 0 0 0 0 0 1 0 0 0 0 0 0 0 0
61 South Korea 1 0 0 0 0 0 0 1 0 0 0 0 0 0 0
62 Costa Rica 1 0 0 0 0 0 0 0 0 0 0 0 0 1 0
63 Antarctica 1 0 0 0 0 1 0 0 0 0 0 0 0 0 0
64 United Arab Emirates 1 0 0 0 0 0 0 0 0 0 0 1 0 0 0

Source code

The following program generates this page:

#!/bin/bash

# Copyright 2021 Fippe
# Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
# The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

api="https://geohashing.site/api.php?format=json"
expandAPI="$api&action=expandtemplates&prop=wikitext&text"
categoryAPI="$api&action=query&list=categorymembers&cmprop=title&cmlimit=500&cmtitle=Category"
transcludedAPI="$api&action=query&prop=transcludedin&tiprop=title&tilimit=500&titles"

dir="/tmp/geohashingstats"
mkdir -p "$dir"
currentyear=$(date +%Y)

function gen {
    date -u +"The following table shows countries by their number of reached and total expeditions as of %F %T UTC. __TOC__"
    echo "==Methodology and Limitations=="
    echo -e "For the purpose of this list, a country is defined as anything that has a [[wikipedia:ISO 3166-1|ISO 3166-1]] code.\n\nThis page is generated by looking where [[:Category:Location templates|location templates]] are transcluded, and at the [[:Category:Expeditions|expeditions category]] and the [[:Category:Coordinates reached|coordinates reached category]]. This page is only as good as those categories.\n\nCheck out the [[#Source code|program's source code]]."
    
    codes=$(curl -s "$categoryAPI:Location_templates" | jq -r ".query.categorymembers[].title" | grep "/" | cut -d "/" -f 2 | while read -r code
        do echo "$code~%7B%7Blocation/$code%7D%7D"
        
        echo -n > "$dir/$code"
        ticontinue="0"
        while [ "$ticontinue" != "null" ]
            do curl -so "$dir/tmp" "$transcludedAPI=Template:Location/$code&tinamespace=0&ticontinue=$ticontinue"
            ticontinue=$(cat "$dir/tmp" | jq -r ".continue.ticontinue")
            cat "$dir/tmp" | jq -r ".query.pages[].transcludedin[].title" >> "$dir/$code"
        done
        rm "$dir/tmp"
    done | tr "\n" ";")
    
    curl -s "$expandAPI=$codes" | jq -r ".expandtemplates.wikitext" | tr ";~" "\n;" | grep -vx "" > "$dir/countries"
    
    for category in "Expeditions" "Coordinates_reached"
        do echo "==${category/_/ }=="
        
        echo -n > "$dir/$category"
        cmcontinue="0"
        while [ "$cmcontinue" != "null" ]
            do curl -so "$dir/tmp" "$categoryAPI:$category&cmcontinue=$cmcontinue"
            cmcontinue=$(cat "$dir/tmp" | jq -r ".continue.cmcontinue")
            cat "$dir/tmp" | jq -r ".query.categorymembers[].title" >> "$dir/$category"
        done
        rm "$dir/tmp"
       
        cat "$dir/countries" | while IFS=';' read -r code country
            do grep -cxf "$dir/$code" "$dir/$category" | tr "\n" " "
            echo "$code $country"
        done > "$dir/$category-countries"

        echo '{|class="wikitable sortable center zebra"'
        echo -n '!#!!Country!!Σ'
        
        for year in $(seq 2008 $currentyear)
            do echo -n '!!'"${year:2:2}"
        done
        sort -nr "$dir/$category-countries" | grep -v "^0" | nl | while read -r rank total code country
            do echo -en "\n|-\n|$rank||[[:Category:Expeditions in $country|$country]]||$total" | sed -e "s/|the /|/"
            
            for year in $(seq 2008 $currentyear)
                do cur=$(grep -xf "$dir/$code" "$dir/$category" | grep -c "^$year")
                echo -n "||$cur"
            done
        done
        echo -e "\n|}"
    done
    echo "==Source code=="
    echo "The following program generates this page:<pre"">$(cat "$0")</pre"">"
    echo "[[Category:Fun stuff]]"
}

gen | tee "$dir/mostactivecountries.wiki"