Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Negative interaction sign for directed edges #10

Open
qmarcou opened this issue Mar 9, 2019 · 1 comment
Open

Negative interaction sign for directed edges #10

qmarcou opened this issue Mar 9, 2019 · 1 comment
Assignees

Comments

@qmarcou
Copy link

qmarcou commented Mar 9, 2019

Hello!
Thanks for putting this great work together!
I would have one feature request in order to make your package suitable for my needs: I'm trying to draw a network where interactions are directed and can be either positive or negative which I would like to be able show graphically (showing positive interaction with a arrow head, and negative one with a dash, see here for example). Would it be possible to add this feature?
Thanks!

@hackl
Copy link
Owner

hackl commented Mar 11, 2019

Thank you very much for your comment. In fact, it would be helpful to simply change the look of the arrows. In the next version I will try to take this into account. In the meantime you can help yourself with the style option:

\documentclass{standalone}
\usepackage{tikz-network}
\begin{document}
\begin{tikzpicture}
% Vertices
\Vertex[x=0,y=-0,label=a]{A} \Vertex[x=3,y=-0,label=b]{B}
\Vertex[x=0,y=-1,label=c]{C} \Vertex[x=3,y=-1,label=d]{D}
\Vertex[x=0,y=-2,label=e]{E} \Vertex[x=3,y=-2,label=f]{F}

% Edges
\Edge[Direct](A)(B)
\Edge[style={-{Bar}, dashed}](C)(D)
\Edge[style={-{Turned Square[length=0.2cm,width=0.2cm]}}](E)(F)
\end{tikzpicture}
\end{document}

PS: An overview of all available arrow tips can be found in the TikZ & PGF manual section 16.5.

@hackl hackl self-assigned this Mar 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants