Home | Trees | Indices | Help |
|
---|
|
object --+ | GraphBase
Low-level representation of a graph.
Don't use it directly, use igraph.Graph instead.
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
a new object with type S, a subtype of T |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
integer |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
boolean |
|
||
|
|||
|
|||
|
|||
boolean |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
integer |
|
||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
Inherited from |
|
|||
Inherited from |
|
Generates a graph from its adjacency matrix.
|
Generates a graph based on asymmetric vertex types and connection probabilities. This is the asymmetric variant of Graph.Preference. A given number of vertices are generated. Every vertex is assigned to an "incoming" and an "outgoing" vertex type according to the given joint type probabilities. Finally, every vertex pair is evaluated and a directed edge is created between them with a probability depending on the "outgoing" type of the source vertex and the "incoming" type of the target vertex.
|
Generates a graph from the Graph Atlas.
Reference: An Atlas of Graphs by Ronald C. Read and Robin J. Wilson, Oxford University Press, 1998. |
Generates a graph based on the Barabasi-Albert model.
Reference: Barabasi, A-L and Albert, R. 1999. Emergence of scaling in random networks. Science, 286 509-512. |
Generates a de Bruijn graph with parameters (m, n) A de Bruijn graph represents relationships between strings. An alphabet of m letters are used and strings of length n are considered. A vertex corresponds to every possible string and there is a directed edge from vertex v to vertex w if the string of v can be transformed into the string of w by removing its first letter and appending a letter to it. Please note that the graph will have m^n vertices and even more edges, so probably you don't want to supply too big numbers for m and n.
|
Generates a graph with a given degree sequence.
|
Generates a graph based on the Erdos-Renyi model.
|
Generates a graph based on a simple growing model with vertex types. A single vertex is added at each time step. This new vertex tries to connect to k vertices in the graph. The probability that such a connection is realized depends on the types of the vertices involved.
|
Generates a famous graph based on its name. Several famous graphs are known to
|
Generates a graph based on the forest fire model The forest fire model is a growin graph model. In every time step, a new vertex is added to the graph. The new vertex chooses an ambassador (or more than one if ambs>1) and starts a simulated forest fire at its ambassador(s). The fire spreads through the edges. The spreading probability along an edge is given by fw_prob. The fire may also spread backwards on an edge by probability fw_prob * bw_factor. When the fire ended, the newly added vertex connects to the vertices ``burned'' in the previous fire.
|
Generates a full graph (directed or undirected, with or without loops).
|
Generates a full citation graph A full citation graph is a graph where the vertices are indexed from 0 to n-1 and vertex i has a directed edge towards all vertices with an index less than i.
|
Generates a random geometric graph. The algorithm drops the vertices randomly on the 2D unit square and connects them if they are closer to each other than the given radius.
|
Generates a growing random graph.
|
Generates a graph with a given isomorphy class.
|
Generates a Kautz graph with parameters (m, n) A Kautz graph is a labeled graph, vertices are labeled by strings of length n+1 above an alphabet with m+1 letters, with the restriction that every two consecutive letters in the string must be different. There is a directed edge from a vertex v to another vertex w if it is possible to transform the string of v into the string of w by removing the first letter and appending a letter to it.
|
Generates a graph from LCF notation. LCF is short for Lederberg-Coxeter-Frucht, it is a concise notation for 3-regular Hamiltonian graphs. It consists of three parameters, the number of vertices in the graph, a list of shifts giving additional edges to a cycle backbone and another integer giving how many times the shifts should be performed. See http://mathworld.wolfram.com/LCFNotation.html for details.
|
Generates a regular lattice.
|
Generates a graph based on vertex types and connection probabilities. This is practically the nongrowing variant of Graph.Establishment. A given number of vertices are generated. Every vertex is assigned to a vertex type according to the given type probabilities. Finally, every vertex pair is evaluated and an edge is created between them with a probability depending on the types of the vertices involved.
|
Reads a graph from a file conforming to the DIMACS minimum-cost flow file format. For the exact description of the format, see http://lpsolve.sourceforge.net/5.5/DIMACS.htm Restrictions compared to the official description of the format:
|
Reads an edge list from a file and creates a graph based on it. Please note that the vertex indices are zero-based.
|
Reads a GML file and creates a graph based on it.
|
Reads a GraphML format file and creates a graph based on it.
|
Reads an .lgl file used by LGL. It is also useful for creating graphs from "named" (and optionally weighted) edge lists. This format is used by the Large Graph Layout program. See the documentation of LGL regarding the exact format description. LGL originally cannot deal with graphs containing multiple or loop edges, but this condition is not checked here, as igraph is happy with these.
|
Reads an .ncol file used by LGL. It is also useful for creating graphs from "named" (and optionally weighted) edge lists. This format is used by the Large Graph Layout program. See the documentation of LGL regarding the exact format description. LGL originally cannot deal with graphs containing multiple or loop edges, but this condition is not checked here, as igraph is happy with these.
|
Reads a Pajek format file and creates a graph based on it.
|
Generates a graph based on a stochastic model where the probability of an edge gaining a new node is proportional to the edges gained in a given time window.
|
Generates a ring graph.
|
Generates a star graph.
|
Generates a tree in which almost all vertices have the same number of children.
|
|
Generates a graph from its adjacency matrix.
|
Returns the igraph graph encapsulated by the Python object as a PyCObject .A PyObject is barely a regular C pointer. This function should not be used directly by igraph users, it is useful only in the case when the underlying igraph object must be passed to another C code through Python. |
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
|
|
Registers a destructor to be called when the object is freed by Python. This function should not be used directly by igraph users. |
str(x)
|
Adds edges to the graph.
|
Adds vertices to the graph.
|
Returns adjacent edges to a given vertex. |
Decides whether two given vertices are directly connected.
|
Returns the list of articulation points in the graph. A vertex is an articulation point if its removal increases the number of connected components in the graph. |
|
Calculates Kleinberg's authority score for the vertices of the graph
See Also: hub_score() |
Calculates the average path length in a graph.
|
Calculates or estimates the betweenness of nodes in a graph. Keyword arguments:
|
Conducts a breadth first search (BFS) on the graph. |
Constructs a breadth first search (BFS) iterator of the graph.
|
Calculates bibliographic coupling scores for given vertices in a graph.
|
Calculates the biconnected components of the graph.
|
Returns the clique number of the graph. The clique number of the graph is the size of the largest clique. See Also: largest_cliques() for the largest cliques. |
Returns some or all cliques of the graph as a list of tuples. A clique is a complete subgraph -- a set of vertices where an edge is present between any two of them (excluding loops)
|
Calculates the closeness centralities of given nodes in a graph. The closeness centerality of a vertex measures how easily other vertices can be reached from it (or the other way: how easily it can be reached from the other vertices). It is defined as the number of the number of vertices minus one divided by the sum of the lengths of all geodesics from/to the given vertex. If the graph is not connected, and there is no path between two vertices, the number of vertices is used instead the length of the geodesic. This is always longer than the longest possible geodesic.
|
Calculates the (strong or weak) clusters for a given graph.
Attention: this function has a more convenient interface in class Graph which wraps the result in a VertexClustering object. It is advised to use that. |
Calculates cocitation scores for given vertices in a graph.
|
Community structure detection based on the betweenness of the edges in the network. This algorithm was invented by M Girvan and MEJ Newman, see: M Girvan and MEJ Newman: Community structure in social and biological networks, Proc. Nat. Acad. Sci. USA 99, 7821-7826 (2002). The idea is that the betweenness of the edges connecting two communities is typically high. So we gradually remove the edge with the highest betweenness from the network and recalculate edge betweenness after every removal, as long as all edges are removed.
Attention: this function is wrapped in a more convenient syntax in the derived class Graph. It is advised to use that instead of this version. |
Finds the community structure of the graph according to the algorithm of Clauset et al based on the greedy optimization of modularity. This is a bottom-up algorithm: initially every vertex belongs to a separate community, and communities are merged one by one. In every step, the two communities being merged are the ones which result in the maximal increase in modularity.
Attention: this function is wrapped in a more convenient syntax in the derived class Graph. It is advised to use that instead of this version. Reference: A. Clauset, M. E. J. Newman and C. Moore: Finding community structure in very large networks. Phys Rev E 70, 066111 (2004). See Also: modularity() |
A proper implementation of Newman's eigenvector community structure detection. Each split is done by maximizing the modularity regarding the original network. See the reference for details.
Attention: this function is wrapped in a more convenient syntax in the derived class Graph. It is advised to use that instead of this version. Reference: MEJ Newman: Finding community structure in networks using the eigenvectors of matrices, arXiv:physics/0605087 |
A naive implementation of Newman's eigenvector community structure detection. This function splits the network into two components according to the leading eigenvector of the modularity matrix and then recursively takes the given number of steps by splitting the communities as individual networks. This is not the correct way, however, see the reference for explanation. Consider using the correct community_leading_eigenvector method instead.
Attention: this function is wrapped in a more convenient syntax in the derived class Graph. It is advised to use that instead of this version. Reference: MEJ Newman: Finding community structure in networks using the eigenvectors of matrices, arXiv:physics/0605087 |
Finds the community structure of the graph according to the random walk method of Latapy & Pons. The basic idea of the algorithm is that short random walks tend to stay in the same community. The method provides a dendrogram.
Attention: this function is wrapped in a more convenient syntax in the derived class Graph. It is advised to use that instead of this version. Reference: Pascal Pons, Matthieu Latapy: Computing communities in large networks using random walks, http://arxiv.org/abs/physics/0512106. See Also: modularity() |
Returns the complementer of the graph
|
Calculates Burt's constraint scores for given vertices in a graph. Burt's constraint is higher if ego has less, or mutually stronger related (i.e. more redundant) contacts. Burt's measure of constraint, C[i], of vertex i's ego network V[i], is defined for directed and valued graphs as follows: C[i] = sum( sum( (p[i,q] p[q,j])^2, q in V[i], q != i,j ), j in V[], j != i) for a graph of order (ie. number od vertices) N, where proportional tie strengths are defined as follows: p[i,j]=(a[i,j]+a[j,i]) / sum(a[i,k]+a[k,i], k in V[i], k != i), a[i,j] are elements of A and the latter being the graph adjacency matrix. For isolated vertices, constraint is undefined.
|
Finds the coreness (shell index) of the vertices of the network. The k-core of a graph is a maximal subgraph in which each vertex has at least degree k. (Degree here means the degree in the subgraph of course). The coreness of a vertex is k if it is a member of the k-core but not a member of the k+1-core.
Reference: Vladimir Batagelj, Matjaz Zaversnik: An O(m) Algorithm for Core Decomposition of Networks. |
Determines the number of isomorphisms between the graph and another one
|
Counts the multiplicities of the given edges.
|
Determines the number of subisomorphisms between the graph and another one
|
Decomposes the graph into subgraphs.
|
Returns some vertex degrees from the graph. This method accepts a single vertex ID or a list of vertex IDs as a parameter, and returns the degree of the given vertices (in the form of a single integer or a list, depending on the input parameter). |
Removes edges from the graph. All vertices will be kept, even if they lose all their edges. Nonexistent edges will be silently ignored.
|
Deletes vertices and all its edges from the graph.
|
Calculates the density of the graph.
|
Calculates the diameter of the graph.
|
Creates the disjoint union of two (or more) graphs.
|
Dyad census, as defined by Holland and Leinhardt Dyad census means classifying each pair of vertices of a directed graph into three categories: mutual, there is an edge from a to b and also from b to a; asymmetric, there is an edge either from a to b or from b to a but not the other way and null, no edges between a and b.
Attention: this function has a more convenient interface in class Graph which wraps the result in a DyadCensus object. It is advised to use that. |
Counts the number of edges.
|
|
Calculates or estimates the edge betweennesses in a graph.
|
Calculates the edge connectivity of the graph or between some vertices. The edge connectivity between two given vertices is the number of edges that have to be removed in order to disconnect the two vertices into two separate components. This is also the number of edge disjoint directed paths between the vertices. The edge connectivity of the graph is the minimal edge connectivity over all vertex pairs. This method calculates the edge connectivity of a given vertex pair if both the source and target vertices are given. If none of them is given (or they are both negative), the overall edge connectivity is returned.
|
Calculates the eigenvector centralities of the vertices in a graph.
|
Returns two vertex IDs whose distance equals the actual diameter of the graph. If there are many shortest paths with the length of the diameter, it returns the first one it founds.
|
Returns the adjacency matrix of a graph.
|
Calculates all of the shortest paths from/to a given node in a graph.
|
Returns a path with the actual diameter of the graph. If there are many shortest paths with the length of the diameter, it returns the first one it founds.
|
Returns the edge ID of an arbitrary edge between vertices v1 and v2
|
Returns all isomorphisms between the graph and another one
|
Calculates the shortest paths from/to a given node in a graph.
|
Returns all subisomorphisms between the graph and another one
|
Returns the girth of the graph. The girth of a graph is the length of the shortest circle in it.
|
Calculates Kleinberg's hub score for the vertices of the graph
See Also: authority_score() |
Returns the independence number of the graph. The independence number of the graph is the size of the largest independent vertex set. See Also: largest_independent_vertex_sets() for the largest independent vertex sets |
Returns some or all independent vertex sets of the graph as a list of tuples. Two vertices are independent if there is no edge between them. Members of an independent vertex set are mutually independent.
|
Creates the intersection of two (or more) graphs.
|
Decides whether the graph is connected.
|
Checks whether a specific set of edges contain loop edges
|
Checks whether an edge is a multiple edge. Also works for a set of edges -- in this case, every edge is checked one by one. Note that if there are multiple edges going between a pair of vertices, there is always one of them that is not reported as multiple (only the others). This allows one to easily detect the edges that have to be deleted in order to make the graph free of multiple edges.
|
Checks whether an edge has an opposite pair. Also works for a set of edges -- in this case, every edge is checked
one by one. The result will be a list of booleans (or a single boolean if
only an edge index is supplied), every boolean corresponding to an edge
in the edge set supplied.
|
Checks whether the graph is simple (no loop or multiple edges).
|
Returns the isomorphy class of the graph or its subgraph. Isomorphy class calculations are implemented only for graphs with 3 or 4 nodes.
|
Checks whether the graph is isomorphic with another graph. The algorithm being used is selected using a simple heuristic:
|
Checks whether the graph is isomorphic with another graph, using the BLISS isomorphism algorithm.
|
Checks whether the graph is isomorphic with another graph, using the VF2 isomorphism algorithm.
|
Returns the Laplacian matrix of a graph. The Laplacian matrix is similar to the adjacency matrix, but the edges are denoted with -1 and the diagonal contains the node degrees. Normalized Laplacian matrices have 1 or 0 in their diagonals (0 for nodes with no edges), edges are denoted by 1 / sqrt(d_i * d_j) where d_i is the degree of node i. Multiple edges and self-loops are silently ignored. Although it is possible to calculate the Laplacian matrix of a directed graph, it does not make much sense.
|
Returns the largest cliques of the graph as a list of tuples. Quite intuitively a clique is considered largest if there is no clique with more vertices in the whole graph. All largest cliques are maximal (i.e. nonextendable) but not all maximal cliques are largest. See Also: clique_number() for the size of the largest cliques or maximal_cliques() for the maximal cliques |
Returns the largest independent vertex sets of the graph as a list of tuples. Quite intuitively an independent vertex set is considered largest if there is no other set with more vertices in the whole graph. All largest sets are maximal (i.e. nonextendable) but not all maximal sets are largest. See Also: independence_number() for the size of the largest independent vertex sets or maximal_independent_vertex_sets() for the maximal (nonextendable) independent vertex sets |
Places the vertices of the graph uniformly on a circle.
|
Places the vertices on a 2D plane according to the DrL layout algorithm. This is an algorithm suitable for quite large graphs, but it can be
surprisingly slow for small ones (where the simpler force-based layouts
like
|
Places the vertices on a 2D plane according to the Fruchterman-Reingold algorithm. This is a force directed layout, see Fruchterman, T. M. J. and Reingold, E. M.: Graph Drawing by Force-directed Placement. Software -- Practice and Experience, 21/11, 1129--1164, 1991
|
Places the vertices in the 3D space according to the Fruchterman-Reingold grid algorithm. This is a force directed layout, see Fruchterman, T. M. J. and Reingold, E. M.: Graph Drawing by Force-directed Placement. Software -- Practice and Experience, 21/11, 1129--1164, 1991
|
This is a port of the graphopt layout algorithm by Michael Schmuhl. graphopt version 0.4.1 was rewritten in C and the support for layers was removed. graphopt uses physical analogies for defining attracting and repelling forces among the vertices and then the physical system is simulated until it reaches an equilibrium or the maximal number of iterations is reached. See http://www.schmuhl.org/graphopt/ for the original graphopt.
|
Places the vertices on a 2D plane according to the Fruchterman-Reingold grid algorithm. This is a modified version of a force directed layout, see Fruchterman, T. M. J. and Reingold, E. M.: Graph Drawing by Force-directed Placement. Software -- Practice and Experience, 21/11, 1129--1164, 1991. The algorithm partitions the 2D space to a grid and vertex repulsion is then calculated only for vertices nearby.
|
Places the vertices on a plane according to the Kamada-Kawai algorithm. This is a force directed layout, see Kamada, T. and Kawai, S.: An Algorithm for Drawing General Undirected Graphs. Information Processing Letters, 31/1, 7--15, 1989.
|
Places the vertices in the 3D space according to the Kamada-Kawai algorithm. This is a force directed layout, see Kamada, T. and Kawai, S.: An Algorithm for Drawing General Undirected Graphs. Information Processing Letters, 31/1, 7--15, 1989.
|
Places the vertices on a 2D plane according to the Large Graph Layout.
|
Places the vertices of the graph randomly in a 2D space.
|
Places the vertices of the graph randomly in a 3D space.
|
Places the vertices on a 2D plane according to the Reingold-Tilford layout algorithm.
See Also: layout_reingold_tilford_circular Reference: EM Reingold, JS Tilford: Tidier Drawings of Trees. IEEE Transactions on Software Engineering 7:22, 223-228, 1981. |
Circular Reingold-Tilford layout for trees. This layout is similar to the Reingold-Tilford layout, but the vertices are placed in a circular way, with the root vertex in the center.
See Also: layout_reingold_tilford Reference: EM Reingold, JS Tilford: Tidier Drawings of Trees. IEEE Transactions on Software Engineering 7:22, 223-228, 1981. |
Places the vertices of the graph uniformly on a sphere.
|
Returns the line graph of the graph. The line graph L(G) of an undirected graph is defined as follows: L(G) has one vertex for each edge in G and two vertices in L(G) are connected iff their corresponding edges in the original graph share an end point. The line graph of a directed graph is slightly different: two vertices are connected by a directed edge iff the target of the first vertex's corresponding edge is the same as the source of the second vertex's corresponding edge. |
Returns the maximum degree of a vertex set in the graph. This method accepts a single vertex ID or a list of vertex IDs as a parameter, and returns the degree of the given vertices (in the form of a single integer or a list, depending on the input parameter). |
Returns the maximum flow between the source and target vertices.
|
Returns the maximal cliques of the graph as a list of tuples. A maximal clique is a clique which can't be extended by adding any other vertex to it. A maximal clique is not necessarily one of the largest cliques in the graph. See Also: largest_cliques() for the largest cliques. |
Returns the maximal independent vertex sets of the graph as a list of tuples. A maximal independent vertex set is an independent vertex set which can't be extended by adding any other vertex to it. A maximal independent vertex set is not necessarily one of the largest independent vertex sets in the graph. See Also: largest_independent_vertex_sets() for the largest independent vertex sets Reference: S. Tsukiyama, M. Ide, H. Ariyoshi and I. Shirawaka: A new algorithm for generating all the maximal independent sets. SIAM J Computing, 6:505--517, 1977. |
Calculates the minimum cut in a graph. Right now it is implemented only for undirected graphs, in which case it uses the Stoer-Wagner algorithm, as described in the reference given below. The minimum cut is the minimum set of edges which needs to be removed to disconnect the graph. The minimum is calculated using the weights (capacities) of the edges, so the cut with the minimum total capacity is calculated.
Reference: M. Stoer, F. Wagner: A simple min-cut algorithm. Journal of the ACM 44(4):585-591, 1997. |
Returns the minimum cut between the source and target vertices.
|
Calculates the modularity of the graph with respect to some vertex types. The modularity of a graph w.r.t. some division measures how good the
division is, or how separated are the different vertex types from each
other. It is defined as Q=1/(2m) *
sum(Aij-ki*kj/(2m)delta(ci,cj),i,j). m is the
number of edges, Aij is the element of the A adjacency matrix in row i and
column j, ki is the degree of
node i, kj is the degree of node
j, and Ci and If edge weights are given, the definition of modularity is modified as follows: Aij becomes the weight of the corresponding edge, ki is the total weight of edges adjacent to vertex i, kj is the total weight of edges adjacent to vertex j and m is the total edge weight in the graph.
Attention:
method overridden in Graph to allow VertexClustering objects as a parameter. This
method is not strictly necessary, since the VertexClustering class provides a variable called
Reference: MEJ Newman and M Girvan: Finding and evaluating community structure in networks. Phys Rev E 69 026113, 2004. |
Counts the number of motifs in the graph Motifs are small subgraphs of a given structure in a graph. It is argued that the motif profile (ie. the number of different motifs in the graph) is characteristic for different types of networks and network function is related to the motifs in the graph. This function is able to find the different motifs of size three and four (ie. the number of different subgraphs with three and four vertices) in the network. In a big network the total number of motifs can be very large, so it takes a lot of time to find all of them. In such cases, a sampling method can be used. This function is capable of doing sampling via the cut_prob argument. This argument gives the probability that a branch of the motif search tree will not be explored.
Reference: S. Wernicke and F. Rasche: FANMOD: a tool for fast network motif detection, Bioinformatics 22(9), 1152--1153, 2006. See Also: Graph.motifs_randesu_no() |
Counts the total number of motifs in the graph Motifs are small subgraphs of a given structure in a graph. This function estimates the total number of motifs in a graph without assigning isomorphism classes to them by extrapolating from a random sample of vertices.
Reference: S. Wernicke and F. Rasche: FANMOD: a tool for fast network motif detection, Bioinformatics 22(9), 1152--1153, 2006. See Also: Graph.motifs_randesu() |
Counts the total number of motifs in the graph Motifs are small subgraphs of a given structure in a graph. This function counts the total number of motifs in a graph without assigning isomorphism classes to them.
Reference: S. Wernicke and F. Rasche: FANMOD: a tool for fast network motif detection, Bioinformatics 22(9), 1152--1153, 2006. See Also: Graph.motifs_randesu() |
Returns adjacent vertices to a given vertex. |
Calculates the Google PageRank values of a graph.
Reference: Sergey Brin and Larry Page: The Anatomy of a Large-Scale Hypertextual Web Search Engine. Proceedings of the 7th World-Wide Web Conference, Brisbane, Australia, April 1998. |
Calculates the Google PageRank values of a graph according to the old PageRank function found in igraph < 0.5. This functions is deprecated and for compatibility purposes only.
Deprecated: the new PageRank function uses the more precise and efficient ARPACK-based implementation Reference: Sergey Brin and Larry Page: The Anatomy of a Large-Scale Hypertextual Web Search Engine. Proceedings of the 7th World-Wide Web Conference, Brisbane, Australia, April 1998. |
Calculates the path length histogram of the graph
Attention: this function is wrapped in a more convenient syntax in the derived class Graph. It is advised to use that instead of this version. |
Permutes the vertices of the graph according to the given permutation and returns the new graph. Vertex k of the original graph will become vertex permutation[k] in the new graph. No validity checks are performed on the permutation vector.
|
Returns the predecessors of a given vertex. Equivalent to calling the Graph.neighbors method with type=IN. |
|
Randomly rewires the graph while preserving the degree distribution. Please note that the rewiring is done "in-place", so the original graph will be modified. If you want to preserve the original graph, use the copy method before.
|
Calculates shortest path lengths for given nodes in a graph.
|
Dice similarity coefficient of vertices. The Dice similarity coefficient of two vertices is twice the number of their common neighbors divided by the sum of their degrees. This coefficient is very similar to the Jaccard coefficient, but usually gives higher similarities than its counterpart.
|
Inverse log-weighted similarity coefficient of vertices. Each vertex is assigned a weight which is 1 / log(degree). The log-weighted similarity of two vertices is the sum of the weights of their common neighbors.
|
Jaccard similarity coefficient of vertices. The Jaccard similarity coefficient of two vertices is the number of their common neighbors divided by the number of vertices that are adjacent to at least one of them.
|
Simplifies a graph by removing self-loops and/or multiple edges.
|
Calculates a minimum spanning tree for a graph (weighted or unweighted)
Reference: Prim, R.C.: Shortest connection networks and some generalizations, Bell System Technical Journal, Vol. 36., 1957, 1389--1401. |
Determines the indices of vertices which are in the same component as a given vertex.
|
Returns a subgraph based on the given vertices.
|
Checks whether a subgraph of the graph is isomorphic with another graph.
|
Returns the successors of a given vertex. Equivalent to calling the Graph.neighbors method with type=OUT. |
Converts an undirected graph to directed.
|
Converts a directed graph to undirected.
|
Calculates a possible topological sorting of the graph. Returns a partial sorting and issues a warning if the graph is not a directed acyclic graph. |
Calculates the local transitivity of given vertices in the graph.
|
Calculates the transitivity (clustering coefficient) of the graph.
|
Triad census, as defined by Davis and Leinhardt Calculating the triad census means classifying every triplets of vertices in a directed graph. A triplet can be in one of 16 states, these are listed in the documentation of the C interface of igraph. Attention: this function has a more convenient interface in class Graph which wraps the result in a TriadCensus object. It is advised to use that. The name of the triplet classes are also documented there. |
Creates the union of two (or more) graphs.
|
Counts the number of vertices.
|
|
Calculates the vertex connectivity of the graph or between some vertices. The vertex connectivity between two given vertices is the number of vertices that have to be removed in order to disconnect the two vertices into two separate components. This is also the number of vertex disjoint directed paths between the vertices (apart from the source and target vertices of course). The vertex connectivity of the graph is the minimal vertex connectivity over all vertex pairs. This method calculates the vertex connectivity of a given vertex pair if both the source and target vertices are given. If none of them is given (or they are both negative), the overall vertex connectivity is returned.
|
Writes the graph in DIMACS format to the given file.
|
Writes the graph in DOT format to the given file. DOT is the format used by the GraphViz software package.
|
Writes the edge list of a graph to a file. Directed edges are written in (from, to) order.
|
Writes the graph in GML format to the given file.
|
Writes the graph to a GraphML file.
|
Writes the edge list of a graph to a file in .lgl format. Note that multiple edges and/or loops break the LGL software, but igraph does not check for this condition. Unless you know that the graph does not have multiple edges and/or loops, it is wise to call simplify() before saving.
|
Writes the edge list of a graph to a file in .ncol format. Note that multiple edges and/or loops break the LGL software, but igraph does not check for this condition. Unless you know that the graph does not have multiple edges and/or loops, it is wise to call simplify() before saving.
|
Writes the graph in Pajek format to the given file.
|
Home | Trees | Indices | Help |
|
---|
Generated by Epydoc 3.0.1 on Sat Aug 16 21:30:46 2008 | http://epydoc.sourceforge.net |