2024 π Daylatest newsbuy art
What do the trees know.Lalehsway, sway, swaymore quotes
very clickable
visualization + math

π Day 2024 Art Posters - A community garden of digits of π
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
2024 π DAY | 768 digits of `\pi` as a garden at night. Explore the gardens (BUY ARTWORK)

The art of Pi (`\pi`), Phi (`\phi`) and `e`


Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2021 π DAY | Good things grow for those who wait.' edition.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2019 π DAY | Hundreds of digits, hundreds of languages and a special kids' edition.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2018 π DAY | Street maps to new destinations.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2017 π DAY | Imagine the sky in a new way.


Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2016 π APPROXIMATION DAY | What would happen if about right was right.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2016 π DAY | These digits really fall for each other.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2015 π DAY | A transcendental experience.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2014 π APPROXIMATION DAY | Spirals into roughness.


Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2014 π DAY | Hypnotizes you into looking.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2014 π DAY | Come into the fold.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2013 π DAY | Where it started.

Pi Art Posters
 / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
CIRCULAR π ART | And other distractions.

This section contains various art work based on `\pi`, `\phi` and `e` that I created over the years.

Some of the numerical art reveals interesting and unexpected observations. For example, the sequence 999999 in π at digit 762 called the Feynman Point. Or that if you calculate π to 13,099,586 digits you will find love.

`\pi` day art and `\pi` approximation day art is kept separate.

Count along ·
Like music with numbers? Try Angels at My Door (Una), Pt vs Ys (Yoshinori Sunahara), 2wicky (Hooverphonic), One (Aimee Mann), Straight to Number One (Touch and Go), 99 luftbaloons (Nena), and Aquarius (Boards of Canada)

Cristian Ilies Vasile had the idea of representing the digits of `\pi` as a path traced by links between successive digits. Each digit is assigned a segment around the circle and a link between segment `i` and `j` corresponds to the appearance of `ij` in `\pi`. For example, the "14" in "3.14..." is drawn as a link between segment 1 and segment 4.

The position of the link on a digit's segment is associated with the position of the digit `\pi`. For example, the "14" link associated with the 2nd digit (1) and the 3rd digit (4) is drawn from position 2 on the 1 segment to position 3 on the 4 segment.

As more digits are added to the path, the image becomes a weaving mandala.

circos art of `\pi`, `\phi` and `e` — transition paths and bubbles

I added to Cristian's representation by showing the number of transitions between digits in a series of concentric circles placed outside the links. This summary representation counts the number of transition links within a region and addresses the question of what kind of digits appear immediately before or after a given digit in `\pi`. The approach is diagrammed below.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
The number of transitions to and from a given digit within a window of 10 digits is shown by circles. For a given digit segment (here, 9) each circle indicates the presence of a specific digit appearing before (inner track) or after (after track) the digit. Solid circles are used for the digit that appears most often and if all digits appear equally often, the choice is arbitrary. In some images the order of digits in the inner track is outward. (zoom)

The original images were generated using the 10-color Brewer paired qualitative palette, which was later modified as shown below.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
For added visual impact, I inverted the color palette and added hue shift and vibrance effects.

The bubbles that count the number of links quickly draw attention to regions where specific digit pairs are frequent. In the image for `\pi` below, which shows transitions for the first 1,000 digits, the large bubble on the 9 segment is due to the "999999" sequence at decimal place 762. This is the Feynman point, which I describe below.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Progression and transition for the first 1,000 digits of `\pi`. Created with Circos. (PNG, BUY ARTWORK)

The image below shows how this representation of `\pi` compares to that of `\phi` and `e`.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Progression and transition for the first 1,000 digits of `\pi`, `\phi` and `e`. Created with Circos. (PNG, BUY ARTWORK)

The transition probabilities for each 10 digit bin for the first 2,000 digits of `\pi`, `\phi` and `e` are shown in the image below.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Progression and transition for the first 2,000 digits of `\pi`, `\phi` and `e`. Created with Circos. (PNG, BUY ARTWORK)

Feynman point

This sequence of 6 9's occurs significantly earlier than expected by chance. Because the distribution and sequence of digits of `\pi` is thought to be normal, we can calculate how frequently we should expect a series of 6 identical digits.

For a given digit, the chance that the next 5 digits are the same is 0.00001 (0.1 that the next digit is the same × 0.1 that the second-nex digit is the same × ...). Therefore the chance that a given position the next 5 digits are not the same is 1 - 1/0.00001 = 0.99999. From this, the chance that `k` consecutive digits don't initiate a 6-digit sequence is therefore 0.99999`k`.

If I ask what is `k` for which this value is 0.5, I need to solve 0.99999`k`, which gives `k` = 69,314. Thus, chances are even (50%) that in a 69,000 digit random sequence we'll see a run of 6 idendical digits. This calculation is an approximation.

It's fun to look for words in `\pi`. For example, love appears at 13,099,586th digit.

A tangent into randomness

The digits of `\pi` are, as far as we know, randomly distributed. Art based on its digits therefore as a quality that is influenced by this random distribution. To provide a reference of what such a random pattern looks like, below are 16 random numbers represented in the same way. They're all different, yet strangely the same.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Digit transition paths of sixteen 1,000 digit random numbers. (PNG, BUY ARTWORK)

Circos art of `\pi`—heaps of bubbles

Below are more images by Cristian Ilies Vasile, where dots are used to represent the adjacency between digits. As in the image above, each digit 0-9 is represented by a colored segment. For each digit sequence `ij`, a dot is placed on the `i`th segment at the position of `i` colored by `j`.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
In a digit bubble heap, a digit is represented by a bubble and placed on the segment of its previous neighbour at the index position of the neighbour.

For example, for `\pi` the dot coordinates for the first 7 digits are (segment:position:label) 3:0:1 → 1:1:4 → 4:2:1 → 1:3:5 → 5:4:9 ...

segment position colored_by

3       0        1
1       1        4
4       2        1
1       3        5
5       4        9
9       5        2
2       6        6 

Because there is a large number of digits, the dots stack up near their position to avoid overlapping. The layout of the dots is automated by Circos' text track layout.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Progression and transition for the first 10,000 digits of `\pi`. Created with Circos. (PNG, BUY ARTWORK)

spiral art of `\pi`

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
The Archimedean spiral embodies `\pi`.

By mapping the digits onto a red-yellow-blue Brewer palette (0 9) and placing them as circles on an Archimedean spiral a dense and pleasant layout can be obtained.

Why the Archimedean spiral? This spiral is defined as `r = a + b \theta` and has the interesting property that a ray from the origin will intersect the spiral every `2 pi b`. Thus, each spiral can accomodate inscribed circles of radius `\pi b`.

Why the Brewer palette? These color schemes have some very useful perceptual properties and are commonly used to encode quantitative and categorical data.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
The digits of π assembled along an Archimedean spiral.
Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
Calculating (x,y) coordinates for each digit along the Archimedean spiral.
Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Distribution of the first 13,689 digits of π. (PNG, BUY ARTWORK)
Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Distribution of the first 3,422, 13,689 and 123,201 digits of π. (PNG, BUY ARTWORK)

I have use the Archimedean spiral to make art for `\pi` approximation day

Pi Approximation Day Art Poster / Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca buy artwork
Pi Approximation Day Art Poster | July 22nd is Pi Approximation Day. Celebrate with this post-modern poster. (PNG, BUY ARTWORK)
news + thoughts

Propensity score matching

Mon 16-09-2024

I don’t have good luck in the match points. —Rafael Nadal, Spanish tennis player

In many experimental designs, we need to keep in mind the possibility of confounding variables, which may give rise to bias in the estimate of the treatment effect.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
Nature Methods Points of Significance column: Propensity score matching. (read)

If the control and experimental groups aren't matched (or, roughly, similar enough), this bias can arise.

Sometimes this can be dealt with by randomizing, which on average can balance this effect out. When randomization is not possible, propensity score matching is an excellent strategy to match control and experimental groups.

Kurz, C.F., Krzywinski, M. & Altman, N. (2024) Points of significance: Propensity score matching. Nat. Methods 21:1770–1772.

Nasa to send our human genome discs to the Moon

Sat 23-03-2024

We'd like to say a ‘cosmic hello’: mathematics, culture, palaeontology, art and science, and ... human genomes.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
SANCTUARY PROJECT | A cosmic hello of art, science, and genomes. (details)
Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
SANCTUARY PROJECT | Benoit Faiveley, founder of the Sanctuary project gives the Sanctuary disc a visual check at CEA LeQ Grenoble (image: Vincent Thomas). (details)
Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
SANCTUARY PROJECT | Sanctuary team examines the Life disc at INRIA Paris Saclay (image: Benedict Redgrove) (details)

Comparing classifier performance with baselines

Fri 22-03-2024

All animals are equal, but some animals are more equal than others. —George Orwell

This month, we will illustrate the importance of establishing a baseline performance level.

Baselines are typically generated independently for each dataset using very simple models. Their role is to set the minimum level of acceptable performance and help with comparing relative improvements in performance of other models.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
Nature Methods Points of Significance column: Comparing classifier performance with baselines. (read)

Unfortunately, baselines are often overlooked and, in the presence of a class imbalance, must be established with care.

Megahed, F.M, Chen, Y-J., Jones-Farmer, A., Rigdon, S.E., Krzywinski, M. & Altman, N. (2024) Points of significance: Comparing classifier performance with baselines. Nat. Methods 21:546–548.

Happy 2024 π Day—
sunflowers ho!

Sat 09-03-2024

Celebrate π Day (March 14th) and dig into the digit garden. Let's grow something.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
2024 π DAY | A garden of 1,000 digits of π. (details)

How Analyzing Cosmic Nothing Might Explain Everything

Thu 18-01-2024

Huge empty areas of the universe called voids could help solve the greatest mysteries in the cosmos.

My graphic accompanying How Analyzing Cosmic Nothing Might Explain Everything in the January 2024 issue of Scientific American depicts the entire Universe in a two-page spread — full of nothing.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
How Analyzing Cosmic Nothing Might Explain Everything. Text by Michael Lemonick (editor), art direction by Jen Christiansen (Senior Graphics Editor), source: SDSS

The graphic uses the latest data from SDSS 12 and is an update to my Superclusters and Voids poster.

Michael Lemonick (editor) explains on the graphic:

“Regions of relatively empty space called cosmic voids are everywhere in the universe, and scientists believe studying their size, shape and spread across the cosmos could help them understand dark matter, dark energy and other big mysteries.

To use voids in this way, astronomers must map these regions in detail—a project that is just beginning.

Shown here are voids discovered by the Sloan Digital Sky Survey (SDSS), along with a selection of 16 previously named voids. Scientists expect voids to be evenly distributed throughout space—the lack of voids in some regions on the globe simply reflects SDSS’s sky coverage.”

voids

Sofia Contarini, Alice Pisani, Nico Hamaus, Federico Marulli Lauro Moscardini & Marco Baldi (2023) Cosmological Constraints from the BOSS DR12 Void Size Function Astrophysical Journal 953:46.

Nico Hamaus, Alice Pisani, Jin-Ah Choi, Guilhem Lavaux, Benjamin D. Wandelt & Jochen Weller (2020) Journal of Cosmology and Astroparticle Physics 2020:023.

Sloan Digital Sky Survey Data Release 12

constellation figures

Alan MacRobert (Sky & Telescope), Paulina Rowicka/Martin Krzywinski (revisions & Microscopium)

stars

Hoffleit & Warren Jr. (1991) The Bright Star Catalog, 5th Revised Edition (Preliminary Version).

cosmology

H0 = 67.4 km/(Mpc·s), Ωm = 0.315, Ωv = 0.685. Planck collaboration Planck 2018 results. VI. Cosmological parameters (2018).

Error in predictor variables

Tue 02-01-2024

It is the mark of an educated mind to rest satisfied with the degree of precision that the nature of the subject admits and not to seek exactness where only an approximation is possible. —Aristotle

In regression, the predictors are (typically) assumed to have known values that are measured without error.

Practically, however, predictors are often measured with error. This has a profound (but predictable) effect on the estimates of relationships among variables – the so-called “error in variables” problem.

Martin Krzywinski @MKrzywinski mkweb.bcgsc.ca
Nature Methods Points of Significance column: Error in predictor variables. (read)

Error in measuring the predictors is often ignored. In this column, we discuss when ignoring this error is harmless and when it can lead to large bias that can leads us to miss important effects.

Altman, N. & Krzywinski, M. (2024) Points of significance: Error in predictor variables. Nat. Methods 21:4–6.

Background reading

Altman, N. & Krzywinski, M. (2015) Points of significance: Simple linear regression. Nat. Methods 12:999–1000.

Lever, J., Krzywinski, M. & Altman, N. (2016) Points of significance: Logistic regression. Nat. Methods 13:541–542 (2016).

Das, K., Krzywinski, M. & Altman, N. (2019) Points of significance: Quantile regression. Nat. Methods 16:451–452.

Martin Krzywinski | contact | Canada's Michael Smith Genome Sciences CentreBC Cancer Research CenterBC CancerPHSA
Google whack “vicissitudinal corporealization”
{ 10.9.234.152 }