[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[igraph] clusters does not like empty string node names
From: |
Katharina Zweig |
Subject: |
[igraph] clusters does not like empty string node names |
Date: |
Mon, 20 Feb 2012 17:34:46 +0100 |
User-agent: |
Mozilla/5.0 (Windows NT 6.1; rv:10.0.2) Gecko/20120216 Thunderbird/10.0.2 |
Dear all,
I just found an interesting behavior of the clusters function which
might be considered a bug. Here is the minimal code to produce the result:
> v1 <- c("", "Anne", "Bert", "Charlotte")
> v2 <- c("", "Bert", "Charlotte", "Anne")
> df <- data.frame(v1, v2)
> g <- graph.data.frame(df)
> summary(g)
>clusters(g)
As you can see there should be a single node with an empty string name
and a triangle between the other three nodes but due to the empty string
name of the first node the clusters function thinks that all nodes are
singletons.
It seems to be independent of the order in which the 'empty' node name
is given. It got worsed, when I replaced one of the empty names by a
real string: my R GUI crashed....
Hope that helps.
Nina
- [igraph] clusters does not like empty string node names,
Katharina Zweig <=