· Resource · 4 min read
Dynamic graphs on the website
Adding graphs to a website can be powerful, especially when they update automatically. This is a test graphing (automatically) the top 5 journals we publish in. I'm exploring this technique to share data in the future.
Ok, cool. Let’s see if this works! I’m using ChartJS for now to graph this. A javascript component grabs data from our publications and counts how often each journal is there. Then the top 5 is put in a bar graph.
Where do we publish?
With who do we publish?
Nice! Now I can use this technique to share data in the future. Ideally I hope to use this to share sequencing data as well, but that might be challenging given the size. For now it’s fun for statistics and fun little projects.
Citations and publications
per year
cumulative
Update, November 2026: how it is all built
This test got a bit out of hand. There is now a whole page of these: the lab in graphs. Since people ask how it works, here is the short version.
The data
Nothing is typed in by hand, except the list of lab members. Every time the website is rebuilt, a small script asks three sources for fresh data:
- PubMed for the list of our papers, with authors, journal and date.
- Google Scholar for the number of citations per paper and per year.
- OpenAlex for where our co-authors work: the institutions they list on each paper, and the city and coordinates of those institutions.
The answers are saved as plain JSON files next to the code. If a source is down, the previous file is kept, so a hiccup at PubMed never breaks the site. A new paper shows up in every graph by itself after the next rebuild.
Graphs drawn in your browser
The bar charts, the line charts, the citations per paper and the network are still Chart.js, as in the original test. Each one is a small component that receives the data, counts what it needs (papers per journal, papers per co-author, citations per year) and hands the result to Chart.js. They only load when you scroll to them, so a page full of graphs still opens quickly. The colors are read from the same settings as the rest of the site, which is why the graphs follow you into dark mode.
The network is a force-directed graph: every author is a node, and every shared paper is a spring that pulls two authors together, while all nodes push each other away a little. The layout is calculated once and then frozen, so it does not wobble around while you look at it.
Co-authorship network · node size = paper count · edge color = paper · edge weight = shared papers
Maps drawn in advance
The maps work differently: they are finished before the page reaches you. While the site is built, d3-geo takes the country outlines from world-atlas and projects them (Equal Earth, so countries keep their true relative size). The outlines have far more detail than a map this size can show, so points closer together than about half a pixel are thrown out. What is left is written into the page as a plain drawing (SVG). Your browser gets no map library at all, only a few lines of script for the tooltips.
For the collaboration map, every institution from OpenAlex is placed in its city. Cities within 10 km of each other become one dot, because Boston and Cambridge are really one place. The size of a dot is the number of co-authors there, and a line joins two cities that appear on the same paper. Half of the network sits in the Netherlands, in cities a few pixels apart on a world map, hence the close-up.
Utrecht · The Netherlands
87 co-authors · 24 papers
- Utrecht University
- University Medical Center Utrecht
- Oncode Institute
- and 1 more
Amsterdam · The Netherlands
73 co-authors · 16 papers
- University of Amsterdam
- Amsterdam UMC
- Amsterdam UMC Location University of Amsterdam
- and 7 more
Cambridge & Boston · United States
49 co-authors · 16 papers
- Harvard University
- Boston Children's Hospital
- Massachusetts General Hospital
- and 4 more
Rotterdam · The Netherlands
24 co-authors · 5 papers
- Erasmus MC
- Sint Franciscus Gasthuis
- Erasmus University Rotterdam
- and 1 more
Nijmegen · The Netherlands
20 co-authors · 1 paper
- Radboud University Medical Center
- Radboud University Nijmegen
London · United Kingdom
14 co-authors · 2 papers
- Imperial College London
- Asthma UK
- University College London
- and 1 more
Leiden · Netherlands
13 co-authors · 4 papers
- Leiden University Medical Center
- Charles River Laboratories (Netherlands)
Stockholm · Sweden
7 co-authors · 1 paper
- Karolinska Institutet
- Karolinska University Hospital
San Diego · United States
6 co-authors · 2 papers
- University of California San Diego
- Scripps Research Institute
Wageningen · The Netherlands
6 co-authors · 1 paper
- Wageningen University & Research
- Netherlands Institute of Ecology
Waltham · United States
5 co-authors · 2 papers
- Brandeis University
Groningen · The Netherlands
5 co-authors · 1 paper
- University of Groningen
- University Medical Center Groningen
Rijswijk · Netherlands
4 co-authors · 1 paper
- Biomedical Primate Research Centre
Strassen · Luxembourg
4 co-authors · 1 paper
- Luxembourg Institute of Health
Amsterdam-Zuidoost · Netherlands
4 co-authors · 1 paper
- AIMM Therapeutics (Netherlands)
Atlanta · United States
4 co-authors · 1 paper
- Emory University
- Emory National Primate Research Center
New York · United States
3 co-authors · 3 papers
- Weill Cornell Medicine
- Weill Cornell Medical Center
- Icahn School of Medicine at Mount Sinai
Maastricht · The Netherlands
3 co-authors · 1 paper
- Maastricht University
Vancouver · Canada
3 co-authors · 1 paper
- Terry Fox Laboratory
- University of British Columbia
Ghent · Belgium
3 co-authors · 1 paper
- Ghent University
Athens · United States
2 co-authors · 2 papers
- University of Georgia
Davis · United States
2 co-authors · 1 paper
- University of California, Davis
Cambridge · United Kingdom
2 co-authors · 1 paper
- Wellcome Sanger Institute
- European Bioinformatics Institute
- University of Cambridge
Leuven · Belgium
2 co-authors · 1 paper
- KU Leuven
Odense · Denmark
2 co-authors · 1 paper
- University of Southern Denmark
Derio & Bilbao · Spain
2 co-authors · 1 paper
- CIC bioGUNE
- Ikerbasque
- University of the Basque Country
Edmonton · Canada
2 co-authors · 1 paper
- University of Alberta
Ithaca · United States
2 co-authors · 1 paper
- Cornell University
Aarhus · Denmark
1 co-author · 2 papers
- Aarhus University
Iowa City · United States
1 co-author · 1 paper
- University of Iowa
Chicago · United States
1 co-author · 1 paper
- University of Chicago
Seoul · South Korea
1 co-author · 1 paper
- Korea University
Melbourne · Australia
1 co-author · 1 paper
- The University of Melbourne
- Walter and Eliza Hall Institute of Medical Research
Memphis · United States
1 co-author · 1 paper
- St. Jude Children's Research Hospital
Hamburg · Germany
1 co-author · 1 paper
- Leibniz Institute of Virology (LIV)
Montreal · Canada
1 co-author · 1 paper
- Centre Hospitalier de l’Université de Montréal
- Université de Montréal
Valbonne · France
1 co-author · 1 paper
- Institut de Pharmacologie Moléculaire et Cellulaire
Nice · France
1 co-author · 1 paper
- Université Nice Sophia Antipolis
San Francisco · United States
1 co-author · 1 paper
- University of California, San Francisco
Oxford · United Kingdom
1 co-author · 1 paper
- University of Oxford
- MRC Weatherall Institute of Molecular Medicine
Hoofddorp · Netherlands
1 co-author · 1 paper
- Nokia (Netherlands)
Paris · France
1 co-author · 1 paper
- Bioscar
Bonn · Germany
1 co-author · 1 paper
- University of Bonn
Basel · Switzerland
1 co-author · 1 paper
- University Hospital of Basel
Essen · Germany
1 co-author · 1 paper
- Essen University Hospital
- University of Duisburg-Essen
Barcelona · Spain
1 co-author · 1 paper
- Hospital del Mar Research Institute
Madrid · Spain
1 co-author · 1 paper
- Centro de Investigación Biomédica en Red de Enfermedades Respiratorias
Toronto · Canada
1 co-author · 1 paper
- University Health Network
- Princess Margaret Cancer Centre
Guangzhou · China
1 co-author · 1 paper
- Sun Yat-sen University
- The First Affiliated Hospital, Sun Yat-sen University
Münster · Germany
1 co-author · 1 paper
- University of Münster
Dublin · Ireland
1 co-author · 1 paper
- Trinity College Dublin
The team map on the about page is made the same way, from the home countries in the team list.
No library at all
The lab timeline on the graphs page is the simplest of the lot: a list, where every person is a bar positioned with two percentages, the day they joined and the day they left. No graphing library, no script, only HTML and CSS. Not everything needs a framework.

