<div class="gmail_quote">On Tue, Oct 25, 2011 at 10:40 AM, Ivan Lazar Miljenovic <span dir="ltr">&lt;<a href="mailto:ivan.miljenovic@gmail.com">ivan.miljenovic@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div class="im">On 25 October 2011 16:02, Rustom Mody &lt;<a href="mailto:rustompmody@gmail.com">rustompmody@gmail.com</a>&gt; wrote:<br>
&gt; On Mon, Oct 24, 2011 at 10:16 AM, Ivan Lazar Miljenovic<br>
&gt; &lt;<a href="mailto:ivan.miljenovic@gmail.com">ivan.miljenovic@gmail.com</a>&gt; wrote:<br>
&gt;&gt;<br>
&gt;&gt; On 24 October 2011 13:51, Rustom Mody &lt;<a href="mailto:rustompmody@gmail.com">rustompmody@gmail.com</a>&gt; wrote:<br>
&gt;&gt; &gt; How does diagrams compare with graphviz?  If this is an inappropriate<br>
&gt;&gt; &gt; (type-wrong?) question thats ok :-)  Its just that when I last looked at<br>
&gt;&gt; &gt; graphviz I found the documentation somewhat impenetrable -- like much<br>
&gt;&gt; &gt; else<br>
&gt;&gt; &gt; in Hackage -- lots of types, no examples.<br>
&gt;&gt;<br>
&gt;&gt; How is it now, better?  If not, what kind of more documentation would you<br>
&gt;&gt; like?<br>
&gt;<br>
&gt;<br>
&gt; Without claiming to have looked very hard, I looked up grahhviz in hayoo,<br>
&gt; gathered I should be looking at Data.GraphViz and tried clicking everything<br>
&gt; that looked reasonable here<br>
&gt; but still cant find an example of a graph :-) ie a graphviz graph in<br>
&gt; haskell.<br>
<br>
</div>Well, there are indeed examples in there, but not in Data.GraphViz:<br>
that module is aimed more at &quot;how can I convert my existing data into<br>
a Dot representation&quot;, not constructing one by hand.  As of the latest<br>
version (2999.12.*), there are indeed examples for anyone that wants<br>
them:<br>
<br>
* Sample graph in Dot representation used as a base case:<br>
<a href="http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types.html" target="_blank">http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types.html</a><br>

* Using the canonical representation:<br>
<a href="http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types-Canonical.html" target="_blank">http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types-Canonical.html</a><br>

* Using the graph representation:<br>
<a href="http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types-Generalised.html" target="_blank">http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types-Generalised.html</a><br>

* Using the Monadic representation (based upon the dotgen package):<br>
<a href="http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types-Graph.html" target="_blank">http://hackage.haskell.org/packages/archive/graphviz/2999.12.0.3/doc/html/Data-GraphViz-Types-Graph.html</a><br>

<br></blockquote><div><br><br>Thanks.<br><br>In the Data.GraphViz.Types.Generalised page you have the starting line:<br><br>It is sometimes useful to be able to manipulate a Dot graph <em>as</em> an
   actual graph.  This representation lets you do so...<br><br>Evidently some other context is needed to understand this line?<br>[Sorry if I am dense]<br></div></div><br>