Skip to content

Instantly share code, notes, and snippets.

@clemsos
Last active July 3, 2017 17:54
Show Gist options
  • Save clemsos/ca5b795ac730a555035cc781bb21fc5f to your computer and use it in GitHub Desktop.
Save clemsos/ca5b795ac730a555035cc781bb21fc5f to your computer and use it in GitHub Desktop.
v0 Test Carto Univ
<head>
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/noUiSlider/9.0.0/nouislider.css" media="screen" title="no title" charset="utf-8">
<link rel="stylesheet" href="https://unpkg.com/[email protected]/dist/leaflet.css" />
<style>
input[type=range] {
width: 100%
}
#map {
height: 80%;
}
</style>
</head>
<body>
<div id="slider"></div>
<p>Selection : <span id="year">1400</span></p>
<div id="map"></div>
<script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.17/d3.js" charset="utf-8"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/noUiSlider/9.0.0/nouislider.js
" charset="utf-8"></script>
<script src="https://unpkg.com/[email protected]/dist/leaflet.js"></script>
<script>
// setup map
let map = L.map('map').setView([51.505, -0.09], 6);
let url = 'http://tile.stamen.com/toner/{z}/{x}/{y}.png'
let attribution = 'Map tiles by <a href="http://stamen.com">Stamen Design</a>, <a href="http://creativecommons.org/licenses/by/3.0">CC BY 3.0</a> &mdash; Map data &copy; <a href="http://www.openstreetmap.org/copyright">OpenStreetMap</a>'
L.tileLayer(url, {
attribution: attribution,
minZoom: 0,
maxZoom: 20,
ext: 'png'
}).addTo(map);
d3.csv("universites.csv", data => {
const years = Object.keys(data[0]).map(d => parseInt(d) )
// default values
console.log(d3.min(years), d3.max(years))
let year = d3.min(years)
// create slider
const slider = document.getElementById('slider')
noUiSlider.create(slider, {
start: year,
connect: true,
step: 20,
range: {
'min': d3.min(years),
'max': d3.max(years)
}
})
// show slider value on the page
slider.noUiSlider.on('slide', value => {
year = Math.floor(value)
d3.select("#year").text(year)
// show elements on the map
data.forEach( (d,i) => {
console.log(d[year])
})
})
})
</script>
</body>
Université Date de fondation 1200 1225 1250 1270 1275 1300 1325 1350 1375 1378 1390 1394 1400 1403 1420 1425 1430 1440 1445 1450 1455 1460 1465 1470 1475 1480 1485 1490 1495 1500 1505 1510 1511 1515 1520 1525 1526 1527 1530 1535 1540 1541 1542 1543 1545 1546 1547 1550 1552 1553 1554 1555 1557 1559 1560 1561 1562 1563 1564 1565 1566 1569 1570 1575 1577 1578 1580 1581 1585 1586 1588 1589 1590 1592 1595 1598 1600 1601 1605 1608 1610 1615 1620 1625 1630 1633 1635 1640 1643 1644 1645 1647 1649 1650 1651 1655 1660 1665 1670 1675 1679 1680 1681 1684 1685 1686 1690 1695 1698 1700 1705 1710 1715 1720 1722 1725 1730 1735 1740 1750 1760 1764 1766 1770 1775 1780 1785 1790 1800 1810
Aberdeen 1494
Abo 1640
Aix-en-Provence 1409
Alcalà de Henares 1499 M : 2567 M : 3030 M : 3217 M : 3208 M : 3066 M : 2736 M : 2640 M : 3632 M : 2125 M : 2855 M : 2083 M : 2131 M : 1899 M : 1432 M : 1597 M : 1351 M : 864 M : 1244 M : 932 M : 809 M : 843 M : 847 M : 783 M : 519 M : 492 M : 542
Almagro 1550
Altamura 1748
Altdorf bei Nuremberg 1578
Ancona 1562
Angers 1229 R : 714 R : 709 M : 1000 Est : 450
Arezzo 1215
Avignon 1303 R : 866 R : 1581 Est : 1500 R : 408 R : 250 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 86 ; Est : 200 M : 141 M : 316 M : 218 M : 218 M : 391 M : 218 M : 218
Avila 1576
Baeza 1538 M : 331 M : 408 M : 396 M : 526 M : 502 M : 510 M : 508 M : 571 M : 404 M : 251 M : 294 M : 349 M : 332 M : 215 M : 219 M : 246 M : 294 M : 204 M : 217 M : 183 M : 220 M : 245 M : 405 M : 227 M : 198 M : 126 M : 171 M : 139 M : 129 M : 169 M : 197 M : 140 M : 159 M : 154 M : 191 M : 186 M : 169 M : 184 M : 218 M : 168 M : 173 M : 151 M : 204 M : 220 M : 228 M : 90
Bamberg 1647
Barcelone 1450
Basle 1459
Besançon 1691 Est : 1000 Est : 1000 Est : 1000 Est : 1000 Est : 1000 Est : 1500 Est : 1500 Est : 1500 Est : 1500 Est : 1500 Est : 1750 Est : 1750 Est : 1750 Est : 1750 Est : 1750 Est : 1500 Est : 1500 Est : 1500 Est : 1500 Est : 1500
Bologne 1200 Est : 2500 M : 650 M : 400 M : 200 M : 200 M : 200 M : 200
Bonn 1777
Bordeaux 1441
Bourges 1464
Braunsberg 1568
Breslau 1702
Budapest 1389
Burgo de Osma 1555
Caen 1432 M : 205 M : 225 M : 191 M : 132 M : 192 M : 189 M : 176 M : 248 M : 311 M : 246 M : 306 M : 239 M : 237 M : 284 M : 249 M : 292 M : 271 M : 233 M : 239 M : 331 M : 303 M : 298 M : 274
Cagliari 1606
Cahors 1332 R : 61 R : 97 M : 370 M : 370
Cambridge 1208 Est : 650 Est : 1300 Est : 1300 Est : 1300 M : 450 M : 450 M : 450 M : 450 M : 450 M : 450 M : 450 M : 450 M : 294 M : 238 M : 200
Camerino 1727
Catania 1434
Cervera 1714
Coïmbra 1308 M : 537 M : 2882 M : 1877 M : 1877 M : 1877 M : 1877 M : 4000 M : 4000
Copenhaguen 1478 M : 25 M : 25 M : 25 M : 25 M : 25 M : 25 M : 25 M : 25 M : 25 M : 25 M : 25 M : 25
Corte 1765
Cracow 1364 M : 248 M : 248 M : 200 M : 230 M : 250 M : 310 M : 290 M : 240 M : 190 M : 311 M : 160 M : 261 M : 175 M : 212 M : 261 M : 134
Die 1601
Dijon 1722 Est : 200
Dilligen 1551 J : 750
Dôle 1422 M : 51 M : 56 M : 112 M : 32 M : 22 M : 34 M : 62 M : 51 M : 41 M : 90 M : 44 M : 133 M : 82 M : 268 M : 78 M : 60 M : 38 M : 45 M : 78 M : 80 M : 62 M : 59 M : 43 M : 55 M : 75 M : 61 M : 42
Dorpat 1632
Douai 1559 J : 1100 Est : 1100 Est : 1200
Dublin 1592
Duisburg 1655
Edimbourg 1583 Est : 600
Eperjes 1665
Erfurt 1379
Erlangen 1742
Escorial 1587
Evora 1558 J : 1000
Fermo 1303
Ferrara 1391 M : 513 M : 550 M : 550 M : 100 M : 70
Florence 1321
Franeker 1585
Frankfurt-on-Oder 1498
Freiburg-im-Breisgau 1455
Fulda 1735
Gandia 1547
Geneva 1559
Genoa 1471
Gerona 1446
Giessen 1607
Glasgow 1450
Göttingen 1733 M : 625 M : 800
Granada 1531 M : 222 M : 240 M : 238 M : 175 M : 182 M : 168 M : 160 M : 160 M : 126 M : 110 M : 97 M : 156 M : 128 M : 84 M : 42 M : 159 M : 130 M : 119 M : 89 M : 64 M : 118 M : 1 M : 34 M : 204 M : 373 M : 468 M : 555 M : 613 M : 703
Graz 1585
Greifswald 1456 M : 100 M : 40 M : 40 M : 40 M : 40 M : 42 M : 70 M : 44 M : 58 M : 44 M : 38 M : 40 M : 40 M : 28
Grenoble 1339
Groninguen 1614
Halle 1693
Harderwijk 1648
Heidelberg 1385 M : 100
Helmstedt 1574 Est : 425 Est : 300 Est : 200
Huesca 1354
Iéna 1459
Ingolstadt 1668
Innsburck 1550 M : 138 M : 303
Irache 1558
Kassa 1657
Kassel 1633
Kiel 1665
Köln 1388 M : 420 M : 397 M : 415 M : 335 M : 223 M : 108 M : 89
Königsberg 1544
Laguna 1701
Leiden 1575
Leipzig 1409 M : 479 M : 568 M : 584 M : 443 M : 235 M : 125 M : 183
Leuven 1425 M : 800 M : 711 M : 802 M : 863 M : 873 M : 871 M : 800 M : 500 M : 500 M : 500 M : 500
Linz 1674
Lisbonne 1288
Lleida 1300
Lucca 1369
Lund 1666
Lwow 1661
Macerata 1540
Mainz 1476
Mantova 1625
Marburg 1527
Messina 1548
Milano 1556
Modena 1772 M : 315
Molsheim 1617
Monbéliard 1560
Mondovi 1598
Montauban 1671
Montpellier 1220 R : 448 R : 162 R : 96 – incomplet
Moskva 1755
Münster-Westfalen 1622
Nagyszombat 1635
Nancy 1768
Nantes 1460
Napoli 1224 M : 5000
Nice 1559
Nimeguen 1656
Nîmes 1539
Olomouc 1573
Onasbrück 1540
Oñate 1365 M : 102 M : 113 M : 73 M : 86 M : 57 M : 37 M : 22 M : 36 M : 13 M : 15 M : 8 M : 3 M : 2 M : 8 M : 39 M : 37 M : 48 M : 81 M : 82 M : 119 M : 49 M : 52 M : 212
Orange 1552
Orihuela 1235
Orléans 1583 R : 400 R : 878 R : 537
Orthez 1629
Osuna 1548 M : 326 M : 233 M : 183 M : 262 M : 150 M : 240 M : 177 M : 67 M : 78 M : 44 M : 37 M : 31 M : 42 M : 75 M : 48 M : 74 M : 80 M : 61 M : 40 M : 93 M : 197 M : 129 M : 212 M : 216
Oviedo 1574 M : 65 M : 66 M : 215 M : 188 M : 123 M : 142 M : 33 M : 53 M : 247 M : 74 M : 228 M : 173 M : 62 M : 34 M : 91 M : 31 M : 100 M : 200 M : 292 M : 515 M : 508 M : 554 M : 595
Oxford 1208 Est : 1500 Est : 1500-2000 Est : 1700 M : 450 M : 450 M : 450 M : 450 M : 450 M : 450 M : 450 M : 450 M : 321 M : 303 M : 300 M : 300 M : 182
Paderborn 1614
Padova 1222 M : 180 M : 380 M : 200 M : 800 M : 764 M : 1000 M : 1037 M : 379 M : 1000 M : 638 M : 1000 M : 1263 M : 500 M : 300 M : 200 M : 200 M : 200
Palermo 1578
Palma de Mallorca 1483
Pamplona 1619
Paris 1208 Est : 4000 Est : 4000 Est : 4000 Est : 4000 R : 1110 – incomplet Est : 4000 R : 4000 Est : 10000 Gl : 1650 Gl : 1161 Gl : 1944 Gl : 1903 Gl : 1650 Est : 2000 Est : 3500 Est : 3000 Est : 1500
Parma 1412 M : 10 – 15
Pau 1722
Pavia 1361 M : 500 M : 153
Perpignan 1350
Perugia 1308 M : 293 M : 96 M : 61 M : 10
Pisa 1343 M : 600-700 M : 124 M : 90
Poitier 1431 Est : 2000 Est : 2000
Pont-à-Mousson 1572 Est : 400-500
Pozsony 1465
Praha 1347 Est : 1000 Est : 1500-2000
Reims 1548
Rennes 1735
Rinteln 1621
Rome 1303
Rome, Curie 1245
Rostock 1419 M : 220 M : 150 M : 160 M : 45 M : 200 M : 180 M : 80 M : 190 M : 200 M : 210 M : 210 M : 210 M : 42 M : 170 M : 80 M : 30 M : 45
Sahagùn 1534
Saint-Andrews 1410
Saint-Peterburg 1724
Salamanque 1218 M : 5982 M : 4511 M : 4998 M : 5985 M : 5917 M : 5607 M : 5976 M : 6633 M : 6359 M : 4740 M : 5131 M : 4711 M : 5006 M : 5314 M : 5918 M : 5534 M : 4428 M : 4484 M : 3748 M : 3009 M : 2949 M : 3133 M : 2709 M : 2383 M : 2747 M : 2659 M : 2029 M : 2001 M : 2201 M : 2150 M : 1894 M : 1420 M : 1698 M : 1809 M : 2041 M : 2038 M : 2336 M : 2054 M : 2035 M : 1609 M : 1499 M : 1385 M : 1599 M : 1533 M : 1149
Salerno 1231
Salzburg 1620
Santiago de Compostella 1526 M : 3000
Sassari 1671
Saumur 1596
Sedan 1599
Séville 1254 M : 132 M : 115 J : 500 M : 321 M : 302 M : 407 M : 303 J : 1000 ; M : 244 M : 215 M : 272 M : 280 M : 292 M : 204 M : 138 M : 127 M : 114 M : 108 M : 182 M : 115 M : 120 M : 223 M : 194 M : 169 M : 186 M : 230 M : 440
Siena 1246 M : 300 M : 20 – 25 M : 100 M : 100 M : 100 M : 100 M : 100
Sigüenza 1483
Solsona 1614
Strasbourg 1566
Stuttgart 1781
Tolède 1521
Tortosa 1551
Toulouse 1229 R : 1583 R : 1120 Est : 1500-2000 R : 666 Est : 600
Tournon 1548
Trèvise 1318
Trier 1454
Tübingen 1476
Torino 1405 M : 901 M : 2000
Uppsala 1477
Urbino 1506
Utrecht 1636
Valence 1452
Valencia 1500 M : 448 M : 412 M : 1164 M : 1195 M : 1190 M : 1225 M : 993 M : 1500 M : 1354 M : 1313 M : 1418
Valladolid 1250 M : 1305 M : 2000 M : 1610 M : 1869 M : 1653 M : 1585 M : 1294 M : 1250 M : 1384 M : 1403 M : 687 M : 937 M : 920 M : 602 M : 452 M : 422 M : 517 M : 362 M : 573 M : 235 M : 571 M : 366 M : 352 M : 428 M : 1170 M : 1372 M : 1257 M : 1332 M : 1430
Venezia 1470
Verceil 1228
Vérone 1339
Vich 1599
Vienna 1365 M : 800 M : 1000 M : 200
Vilnius 1578
Wittemberg 1502 M : 219 M : 259 M : 431 M : 274 M : 174 M : 265
Würzbourg 1402
Zamosc 1594
Zaragoza 1474 M : 619 M : 435 M : 780 M : 693 M : 365 M : 643 M : 751 M : 973 M : 1953 M : 1502 M : 1725
M : matricules
Est : Estimation
J : collège jésuites
R : rotuli
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment