[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [igraph] Identifying vertices belonging to fully closed triads in la
From: |
Szabolcs Horvát |
Subject: |
Re: [igraph] Identifying vertices belonging to fully closed triads in large graph |
Date: |
Wed, 13 Jun 2018 09:37:25 +0200 |
I am not familiar with the term "fully closed triad", but I assume it
means a complete directed graph on 3 vertices.
If so, you can first convert the graph to undirected in such a way
that only reciprocal edges are kept (as.undirected() function), then
find all triangles. There are multiple way to do this, e.g.
count_triangles() to find triangle adjacent to each vertex (and thus
find all triangles), or finding cliques of size 3 using cliques() with
min=3 and max=3.
An alternative (and likely slower) way is to use one of the subgraph
finder functions to find the specific 3-vertex subgraph you want.
Check subgraph_isomorphic(), in particular the LAD method. This can be
directly used on the directed graph.
On Tue, 12 Jun 2018 at 22:50, Wagner, Stefan <address@hidden> wrote:
>
> Dear igraph-list,
>
>
>
> I am trying to identify all fully closed triads in large directed graphs as
> well as the vertices belonging to them.
>
>
>
> I am aware that triad.census provides a count of all fully closed triads.
> However, I am looking for a way to identify all individual fully closed
> triads in a graph. Ideally, I get a matrix with 3 columns (for each vertice
> in a triad) and n lines for the each fully closed triad in my directed graph.
>
>
>
> I found the following solution in
> https://stackoverflow.com/questions/40597315/igraph-finding-all-subgraphs-of-specified-shape:
> Generate all possible combinations of 3 vertices and use sna’s
> triad.classify to identify the fully closed triads within these combinations.
> However, the number of different vertices in my graphs is too big, to
> generate all possible combinations using the combn command. (At least, I get
> an error message when trying.)
>
>
>
> Is there an alternative approach?
>
>
>
> Thanks for your help,
>
>
>
> Stefan
>
>
>
> _______________________________________________
> igraph-help mailing list
> address@hidden
> https://lists.nongnu.org/mailman/listinfo/igraph-help