Installing graph-tool for Python 3 on Anaconda
Anaconda is a great Python environment, no doubt about that. However, it was not immediately easy to make graph-tool run smoothly on it. That took some time and a little google-fu to make things work.
Edit: as suggested by Morten Grøftehauge, I published this conda environment at https://anaconda.org/ruliana/graph-tool
The dependency with GTK is one of the problems and here I explain what I did to fix them.
First, open “anaconda-navigator” and add three new channels:
- conda-forge
- ostrokach-forge
- pkgw-forge

Then, install the following packages:
- gtk3 (from pkgw-forge)
- pygobject (from conda-forge)
- matplotlib (from conda-forge)
- graph-tool (from ostrokach-forge)

Done!
Open a Python console in this environment and type:
> from graph_tool.all import *
If the import goes fine, graph-tool is properly installed. Go ahead and be happy :)