Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Mastering Python Data Visualization

You're reading from   Mastering Python Data Visualization Generate effective results in a variety of visually appealing charts using the plotting packages in Python

Arrow left icon
Product type Paperback
Published in Oct 2015
Publisher
ISBN-13 9781783988327
Length 372 pages
Edition 1st Edition
Languages
Arrow right icon
Toc

Table of Contents (11) Chapters Close

Preface 1. A Conceptual Framework for Data Visualization 2. Data Analysis and Visualization FREE CHAPTER 3. Getting Started with the Python IDE 4. Numerical Computing and Interactive Plotting 5. Financial and Statistical Models 6. Statistical and Machine Learning 7. Bioinformatics, Genetics, and Network Models 8. Advanced Visualization A. Go Forth and Explore Visualization Index

The directed acyclic graph test

Let's take a look at what a directed acyclic graph (DAG) is first. A directed acyclic graph is a graph that is directed, which means that the edges from a given vertex A to B will be directed in a particular direction (A->B or B->A) and is acyclic. Acyclic graphs are those graphs that are not cyclic, which also means that there is no cycle (they don't go around in cycle).

What is a good example of a DAG? A tree or even a trie. We all know what they are because it was discussed in one of the previous chapters of this book. A good example of using trie is to store the words of dictionaries and have a spell check algorithm. We will not go further into details about this, but in the context of visualization and to check whether a graph is acyclic or not, we will determine the Python packages that offer methods to test whether a graph is acyclic or not.

NetworkX has a convenient function called is_directed_acyclic_graph (Graph). Here is an example...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime
Banner background image