An introduction to the JSON-stat ecosystem. Originally published in July 2013, it was edited in 2015: it was updated to the latest changes in the standard and aspects not directly related to the JSON-stat document format were removed).
A very brief version of this presentation was used at the Data Tuesday BCN (Sept. 17th, 2013).
Boost PC performance: How more available memory can improve productivity
JSON-stat, a simple light standard for all kinds of data disseminators
1. JSON-stat
a simple light standard
for all kinds of data disseminators
Xavier Badosa
@badosa
http://xavierbadosa.com
http://json-stat.org
December, 2015
2. a simple light standard
for all kinds of data disseminators
Who needs to disseminate data?
3. Who needs to disseminate data?
Nowadays? Everybody!
Of course!
NSOs*
Central Banks
Intl. orgs
* National Statistical Offices
Companies
The media
Citizens…
But also
NGOs
a simple light standard
for all kinds of data disseminators
4. How is data usually disseminated?
a simple light standard
for all kinds of data disseminators
15. Simple, for everybody? How?
If you managed to disseminate data
for humans in tables, you should be
able to do it for machines with no effort!
a simple light standard
for all kinds of data disseminators
16. JSON is a data format used in
most APIs. It can include data
and metadata in a single doc.
Simple, for everybody? How?
In JSON.
17. Using a very simple cube model
that mimics a plain old table.
Simple, for everybody? How?
In JSON-stat.
40. ["country", "year", "age", "concept", "sex"]
Criterion:
What does not change, first.
To make sense of this array, dimensions must be ordered.
(Position of dimensions of size 1 is irrelevant.)
41. country
year
age
concept
sex
CA CA CA CA CA CA
2012 2012 2012 2012 2012 2012
Total Total Total Total Total Total
Persons Persons Persons % % %
Total TotalM M FF
What does not change, first.
44. country
year
age
concept
sex
CA CA CA CA CA CA
2012 2012 2012 2012 2012 2012
Total Total Total Total Total Total
Persons Persons Persons % % %
Total TotalM M FF
60. The“unflattening” problem
["country", "year", "age", "concept", "sex"]
[ 1, 1, 20, 2, 3 ]
It’s a simple
mathematical
problem
Compute value
position using
dimension
position & size
[0, 0, 7, 0, 2] → 44
61. Lost in cells?
Method: Row-major order
In computing, row-major order and column-
major order describe methods for arranging
multidimensional arrays in linear storage such
as memory.
68. all pictures from
Blocks picture in slide 1: Soma, by Dru! (CC BY-NC)
Cubic head in slide 13: Portrait by Thomas Leth-Olsen (CC BY)
Rubik’s Cube in slide 18: BW Rubik’s Cube,
by Gerwin Sturm (CC BY-SA)
Shiny cube in slide 48: SONY DSC, by Javier
Manso (CC BY-NC-SA)
Walking girl in slide 61: Sterile, by Lee
Nachtigal (CC BY)
Atomium in slide 66: Fighting Gravity –
Atomium, Brussels, by Jan Faborsky
(CC BY-NC-ND)
Eggs in slide 77: Eggs n. 3, by Leonardo
D’Amico (CC BY-SA-ND)