Skip to content

Commit e4c544c

Browse files
committed
another atempt to restore file
1 parent 5bf6100 commit e4c544c

File tree

1 file changed

+30
-89
lines changed

1 file changed

+30
-89
lines changed

src/notebooks/web-lollipop-plot-with-python-mario-kart-64-world-records.ipynb

Lines changed: 30 additions & 89 deletions
Original file line numberDiff line numberDiff line change
@@ -24,11 +24,11 @@
2424
]
2525
},
2626
{
27-
"cell_type": "markdown",
28-
"metadata": {},
2927
"source": [
3028
"As always, several libraries are needed in order to build the chart. `numpy`, `pandas` and `matplotlib` are pretty usual, but we also need some lesser known libraries like `palettable` to get some nice colors."
31-
]
29+
],
30+
"cell_type": "markdown",
31+
"metadata": {}
3232
},
3333
{
3434
"cell_type": "code",
@@ -69,66 +69,8 @@
6969
"metadata": {},
7070
"outputs": [
7171
{
72+
"output_type": "execute_result",
7273
"data": {
73-
"text/html": [
74-
"<div>\n",
75-
"<style scoped>\n",
76-
" .dataframe tbody tr th:only-of-type {\n",
77-
" vertical-align: middle;\n",
78-
" }\n",
79-
"\n",
80-
" .dataframe tbody tr th {\n",
81-
" vertical-align: top;\n",
82-
" }\n",
83-
"\n",
84-
" .dataframe thead th {\n",
85-
" text-align: right;\n",
86-
" }\n",
87-
"</style>\n",
88-
"<table border=\"1\" class=\"dataframe\">\n",
89-
" <thead>\n",
90-
" <tr style=\"text-align: right;\">\n",
91-
" <th></th>\n",
92-
" <th>track</th>\n",
93-
" <th>type</th>\n",
94-
" <th>shortcut</th>\n",
95-
" <th>player</th>\n",
96-
" <th>system_played</th>\n",
97-
" <th>date</th>\n",
98-
" <th>time_period</th>\n",
99-
" <th>time</th>\n",
100-
" <th>record_duration</th>\n",
101-
" </tr>\n",
102-
" </thead>\n",
103-
" <tbody>\n",
104-
" <tr>\n",
105-
" <th>0</th>\n",
106-
" <td>Luigi Raceway</td>\n",
107-
" <td>Three Lap</td>\n",
108-
" <td>No</td>\n",
109-
" <td>Salam</td>\n",
110-
" <td>NTSC</td>\n",
111-
" <td>1997-02-15</td>\n",
112-
" <td>2M 12.99S</td>\n",
113-
" <td>132.99</td>\n",
114-
" <td>1</td>\n",
115-
" </tr>\n",
116-
" <tr>\n",
117-
" <th>1</th>\n",
118-
" <td>Luigi Raceway</td>\n",
119-
" <td>Three Lap</td>\n",
120-
" <td>No</td>\n",
121-
" <td>Booth</td>\n",
122-
" <td>NTSC</td>\n",
123-
" <td>1997-02-16</td>\n",
124-
" <td>2M 9.99S</td>\n",
125-
" <td>129.99</td>\n",
126-
" <td>0</td>\n",
127-
" </tr>\n",
128-
" </tbody>\n",
129-
"</table>\n",
130-
"</div>"
131-
],
13274
"text/plain": [
13375
" track type shortcut player system_played date \\\n",
13476
"0 Luigi Raceway Three Lap No Salam NTSC 1997-02-15 \n",
@@ -137,11 +79,11 @@
13779
" time_period time record_duration \n",
13880
"0 2M 12.99S 132.99 1 \n",
13981
"1 2M 9.99S 129.99 0 "
140-
]
82+
],
83+
"text/html": "<div>\n<style scoped>\n .dataframe tbody tr th:only-of-type {\n vertical-align: middle;\n }\n\n .dataframe tbody tr th {\n vertical-align: top;\n }\n\n .dataframe thead th {\n text-align: right;\n }\n</style>\n<table border=\"1\" class=\"dataframe\">\n <thead>\n <tr style=\"text-align: right;\">\n <th></th>\n <th>track</th>\n <th>type</th>\n <th>shortcut</th>\n <th>player</th>\n <th>system_played</th>\n <th>date</th>\n <th>time_period</th>\n <th>time</th>\n <th>record_duration</th>\n </tr>\n </thead>\n <tbody>\n <tr>\n <th>0</th>\n <td>Luigi Raceway</td>\n <td>Three Lap</td>\n <td>No</td>\n <td>Salam</td>\n <td>NTSC</td>\n <td>1997-02-15</td>\n <td>2M 12.99S</td>\n <td>132.99</td>\n <td>1</td>\n </tr>\n <tr>\n <th>1</th>\n <td>Luigi Raceway</td>\n <td>Three Lap</td>\n <td>No</td>\n <td>Booth</td>\n <td>NTSC</td>\n <td>1997-02-16</td>\n <td>2M 9.99S</td>\n <td>129.99</td>\n <td>0</td>\n </tr>\n </tbody>\n</table>\n</div>"
14184
},
142-
"execution_count": 3,
14385
"metadata": {},
144-
"output_type": "execute_result"
86+
"execution_count": 3
14587
}
14688
],
14789
"source": [
@@ -150,14 +92,14 @@
15092
]
15193
},
15294
{
153-
"cell_type": "markdown",
154-
"metadata": {},
15595
"source": [
15696
"<br>\n",
15797
"<br>\n",
15898
"<br>\n",
15999
"<br>"
160-
]
100+
],
101+
"cell_type": "markdown",
102+
"metadata": {}
161103
},
162104
{
163105
"cell_type": "markdown",
@@ -172,11 +114,11 @@
172114
]
173115
},
174116
{
175-
"cell_type": "markdown",
176-
"metadata": {},
177117
"source": [
178118
"## Prepare the dataset"
179-
]
119+
],
120+
"cell_type": "markdown",
121+
"metadata": {}
180122
},
181123
{
182124
"cell_type": "markdown",
@@ -363,11 +305,11 @@
363305
]
364306
},
365307
{
366-
"cell_type": "markdown",
367-
"metadata": {},
368308
"source": [
369309
"## Start building the chart"
370-
]
310+
],
311+
"cell_type": "markdown",
312+
"metadata": {}
371313
},
372314
{
373315
"cell_type": "markdown",
@@ -728,31 +670,27 @@
728670
]
729671
},
730672
{
731-
"cell_type": "markdown",
732-
"metadata": {},
733673
"source": [
734674
"## Conclusion"
735-
]
675+
],
676+
"cell_type": "markdown",
677+
"metadata": {}
736678
},
737679
{
738-
"cell_type": "markdown",
739-
"metadata": {},
740680
"source": [
741681
"That was a lot of work! And many more lines of code than using R. But here we are, a pretty good looking lollipop chart showcasing the possibilities offered by Matplotlib, which are basically infinite!"
742-
]
682+
],
683+
"cell_type": "markdown",
684+
"metadata": {}
743685
}
744686
],
745687
"metadata": {
746688
"chartType": "lollipop",
747689
"description": "A highly customized lollipop chart showing world records for the Mario Kart 64 racing game on the Nintendo 64. Built with Python and Matplotlib. This blogpost will guide you through a very custom plot with Matplotlib, including custm fonts, custom scales, custom legends, and more!",
748690
"family": "ranking",
749-
"interpreter": {
750-
"hash": "dca0ade3e726a953b501b15e8e990130d2b7799f14cfd9f4271676035ebe5511"
751-
},
752691
"kernelspec": {
753-
"display_name": "Python 3",
754-
"language": "python",
755-
"name": "python3"
692+
"name": "python3",
693+
"display_name": "Python 3.8.6 64-bit ('base': conda)"
756694
},
757695
"keywords": "python, chart, plot, matplotlib, lollipop, custom",
758696
"language_info": {
@@ -765,12 +703,15 @@
765703
"name": "python",
766704
"nbconvert_exporter": "python",
767705
"pygments_lexer": "ipython3",
768-
"version": "3.9.5"
706+
"version": "3.8.6"
769707
},
770708
"seoDescription": "This post explains how to build a highly customized lollipop plot with Matplotlib. Step by step code snippets with explanations are provided.",
771709
"slug": "web-lollipop-plot-with-python-mario-kart-64-world-records",
772-
"title": "Mario Kart 64 World Records with Python and Matplotlib"
710+
"title": "Mario Kart 64 World Records with Python and Matplotlib",
711+
"interpreter": {
712+
"hash": "dca0ade3e726a953b501b15e8e990130d2b7799f14cfd9f4271676035ebe5511"
713+
}
773714
},
774715
"nbformat": 4,
775716
"nbformat_minor": 2
776-
}
717+
}

0 commit comments

Comments
 (0)