You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
viz.set_caption("It doesn't take much to create text visualizations with Multiplex!")
79
+
viz = drawable.Drawable(plt.figure(figsize=(10, 2)))
80
+
paragraph ="""Anthony Lopes is a Portuguese professional footballer who plays for Olympique Lyonnais as a goalkeeper. He came through the youth ranks at Lyon, being called to the first team in 2011 and making his debut the following year."""
viz.set_title('Profile: Anthony Lopes', loc='left')
84
+
viz.set_caption("""Wikipedia is a useful repository to get more information about anything. Below is an excerpt from the Wikipedia profile of footballer Anthony Lopes.""")
81
85
plt.show()
82
86
83
-
All it takes to draw a simple text visualization is 9 lines of code:
87
+
.. image:: ../examples/exports/2-simple-text.png
88
+
:class:center
89
+
:width:62%
90
+
91
+
All it takes to draw a simple text visualization is 10 lines of code:
84
92
85
93
1. Three lines to import matplotlib, Multiplex and the visualization style;
86
-
2. Set up the visualization object;
87
-
3. Draw and show the visualization, including a title and caption.
94
+
2. Three lines to set up the visualization object, load the data and set the style;
95
+
3. Four lines to draw and show the visualization, including a title and caption.
88
96
89
97
Multiplex abstracts the tedious process of manually programming which elements go where, and lets you create beautiful visualizations with ease.
<spanclass="n">viz</span><spanclass="o">.</span><spanclass="n">set_caption</span><spanclass="p">(</span><spanclass="s2">"It doesn't take much to create text visualizations with Multiplex!"</span><spanclass="p">)</span>
<spanclass="n">paragraph</span><spanclass="o">=</span><spanclass="s2">"""Anthony Lopes is a Portuguese professional footballer who plays for Olympique Lyonnais as a goalkeeper. He came through the youth ranks at Lyon, being called to the first team in 2011 and making his debut the following year."""</span>
<spanclass="n">viz</span><spanclass="o">.</span><spanclass="n">set_title</span><spanclass="p">(</span><spanclass="s1">'Profile: Anthony Lopes'</span><spanclass="p">,</span><spanclass="n">loc</span><spanclass="o">=</span><spanclass="s1">'left'</span><spanclass="p">)</span>
230
+
<spanclass="n">viz</span><spanclass="o">.</span><spanclass="n">set_caption</span><spanclass="p">(</span><spanclass="s2">"""Wikipedia is a useful repository to get more information about anything. Below is an excerpt from the Wikipedia profile of footballer Anthony Lopes."""</span><spanclass="p">)</span>
<p>All it takes to draw a simple text visualization is 10 lines of code:</p>
232
236
<blockquote>
233
237
<div><olclass="arabic simple">
234
238
<li><p>Three lines to import matplotlib, Multiplex and the visualization style;</p></li>
235
-
<li><p>Set up the visualization object;</p></li>
236
-
<li><p>Draw and show the visualization, including a title and caption.</p></li>
239
+
<li><p>Three lines to set up the visualization object, load the data and set the style;</p></li>
240
+
<li><p>Four lines to draw and show the visualization, including a title and caption.</p></li>
237
241
</ol>
238
242
</div></blockquote>
239
243
<p>Multiplex abstracts the tedious process of manually programming which elements go where, and lets you create beautiful visualizations with ease.</p>
0 commit comments