[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [igraph] Labeling vertices
From: |
Tamas Nepusz |
Subject: |
Re: [igraph] Labeling vertices |
Date: |
Fri, 9 Jan 2015 00:53:51 +0100 |
User-agent: |
Mutt/1.5.23 (2014-03-12) |
Judging from your earlier screenshot, it seems like the labels are *lists* of
hashtags and not individual hashtags (as the function assumes). Can you post
a small, reproducible, self-contained example that demonstrates the problem?
T.
On 01/08, Ahmed Abdeen Hamed wrote:
> Yes, thank you!
>
> The function is really simple, it works correctly in other context except
> this one. Here is the implementation:
>
> def is_hashtag(vertex):
> return vertex["name"].startswith("#")
>
> -Ahmed
>
>
>
> On Thu, Jan 8, 2015 at 4:59 PM, Tamas Nepusz <address@hidden> wrote:
>
> > Have you confirmed that your is_hashtag() function is working correctly?
> > For
> > one thing, it seems to me that each vertex contains multiple hash tags, so
> > it
> > could be the case that is_hashtag() is simply returning False for all the
> > vertices.
> >
> > T.
> >
> > On 01/08, Ahmed Abdeen Hamed wrote:
> > > It is still shows the hashtags even though they shouldn't. Here is small
> > > screenshot that shows that there are hashtag appearing. What am I doing
> > > wrong?
> > >
> > > -Ahmed
> > >
> > >
> > > [image: Inline image 1]
> > >
> > > On Thu, Jan 8, 2015 at 4:15 PM, Tamas Nepusz <address@hidden> wrote:
> > >
> > > > > visual_style["vertex_label"] = ["" if is_hashtag(vertex) else
> > > > > vertex["name"] for vertex in g.vs]
> > > > >
> > > > > However, there is a glitch. Suggestions?
> > > > Your code seems okay; what is the problem with it? How did you try to
> > plot
> > > > the
> > > > graph and what glitch did you see?
> > > >
> > > > --
> > > > T.
> > > >
> >
> >
> >
> > --
> > T.
> >
--
T.
- [igraph] Labeling vertices, Ahmed Abdeen Hamed, 2015/01/08
- Re: [igraph] Labeling vertices, Tamas Nepusz, 2015/01/08
- Re: [igraph] Labeling vertices, Ahmed Abdeen Hamed, 2015/01/08
- Re: [igraph] Labeling vertices, Tamas Nepusz, 2015/01/08
- Re: [igraph] Labeling vertices, Ahmed Abdeen Hamed, 2015/01/08
- Re: [igraph] Labeling vertices,
Tamas Nepusz <=
- Re: [igraph] Labeling vertices, Ahmed Abdeen Hamed, 2015/01/08
- Re: [igraph] Labeling vertices, Tamas Nepusz, 2015/01/09
- Re: [igraph] Labeling vertices, Ahmed Abdeen Hamed, 2015/01/09