|
232 | 232 | <td><p> |
233 | 233 | Called when new edges are added to a graph, after the |
234 | 234 | base data structure was modified. A vector containing the endpoints of the |
235 | | - new edges are supplied as an argument. The function is supposd to set up |
| 235 | + new edges are supplied as an argument. The function is supposed to set up |
236 | 236 | default values for each edge attribute that is currently registered on the |
237 | 237 | graph, for all the newly added edges. Expected to return an error code. |
238 | 238 | </p></td> |
|
245 | 245 | attributes of some edges from the old graph (this also includes the |
246 | 246 | deletion of edges). The supplied index vector defines which old edge a new |
247 | 247 | edge corresponds to. Its length is the same as the number of edges in the |
248 | | - new graph, and for each edge it provides the ID of the correspnding edge |
| 248 | + new graph, and for each edge it provides the ID of the corresponding edge |
249 | 249 | in the old graph. The function is supposed to set up the values of the |
250 | 250 | edge attributes of the new graph based on the attributes of the old graph |
251 | 251 | and the provided index vector. Note that the old and the new graph <span class="emphasis"><em>may</em></span> |
|
1253 | 1253 | a single one. Attribute combination lists are used to indicate to the attribute |
1254 | 1254 | handler how to combine the attributes of the original vertices or edges and |
1255 | 1255 | how to derive the final attribute value that is to be assigned to the collapsed |
1256 | | -vertex or edge. For example, <a class="link" href="igraph-Operators.html#igraph_simplify" title="3.9. igraph_simplify — Removes loop and/or multiple edges from the graph."><code class="function">igraph_simplify()</code></a> removes loops and combines |
| 1256 | +vertex or edge. For example, <a class="link" href="igraph-Operators.html#igraph_simplify" title="3.10. igraph_simplify — Removes loop and/or multiple edges from the graph."><code class="function">igraph_simplify()</code></a> removes loops and combines |
1257 | 1257 | multiple edges into a single one; in case of a graph with an edge attribute |
1258 | 1258 | named <code class="constant">weight</code> the attribute combination list can tell the attribute handler |
1259 | 1259 | whether the weight of a collapsed edge should be the sum, the mean or some other |
|
1722 | 1722 | "type", IGRAPH_ATTRIBUTE_COMBINE_FIRST, |
1723 | 1723 | "", IGRAPH_ATTRIBUTE_COMBINE_IGNORE, |
1724 | 1724 | IGRAPH_NO_MORE_ATTRIBUTES); |
1725 | | - <span class="strong"><strong><a class="link" href="igraph-Operators.html#igraph_simplify" title="3.9. igraph_simplify — Removes loop and/or multiple edges from the graph.">igraph_simplify</a></strong></span>(&graph, <span class="emphasis"><em>/*remove_multiple=*/</em></span> true, <span class="emphasis"><em>/*remove_loops=*/</em></span> true, &comb); |
| 1725 | + <span class="strong"><strong><a class="link" href="igraph-Operators.html#igraph_simplify" title="3.10. igraph_simplify — Removes loop and/or multiple edges from the graph.">igraph_simplify</a></strong></span>(&graph, <span class="emphasis"><em>/*remove_multiple=*/</em></span> true, <span class="emphasis"><em>/*remove_loops=*/</em></span> true, &comb); |
1726 | 1726 | <span class="strong"><strong><a class="link" href="igraph-Foreign.html#igraph_write_graph_graphml" title="3.2. igraph_write_graph_graphml — Writes the graph to a file in GraphML format.">igraph_write_graph_graphml</a></strong></span>(&graph, stdout, <span class="emphasis"><em>/*prefixattr=*/</em></span> true); |
1727 | 1727 |
|
1728 | 1728 | <span class="strong"><strong><a class="link" href="igraph-Basic.html#igraph_destroy" title="4.1.4. igraph_destroy — Frees the memory allocated for a graph object.">igraph_destroy</a></strong></span>(&graph); |
|
1920 | 1920 | <span class="strong"><strong><a class="link" href="igraph-Attributes.html#igraph_set_attribute_table" title="1.2. igraph_set_attribute_table — Attach an attribute table.">igraph_set_attribute_table</a></strong></span>(&igraph_cattribute_table); |
1921 | 1921 |
|
1922 | 1922 | <span class="emphasis"><em>/* Create a graph, add some attributes and save it as a GraphML file. */</em></span> |
1923 | | - <span class="strong"><strong><a class="link" href="igraph-Generators.html#igraph_famous" title="1.25. igraph_famous — Create a famous graph by simply providing its name.">igraph_famous</a></strong></span>(&g, "Petersen"); |
| 1923 | + <span class="strong"><strong><a class="link" href="igraph-Generators.html#igraph_famous" title="1.27. igraph_famous — Create a famous graph by simply providing its name.">igraph_famous</a></strong></span>(&g, "Petersen"); |
1924 | 1924 | <span class="strong"><strong><a class="link" href="igraph-Attributes.html#SETGAS" title="4.2.6. SETGAS — Set a string graph attribute">SETGAS</a></strong></span>(&g, "name", "Petersen's graph"); |
1925 | 1925 | <span class="strong"><strong><a class="link" href="igraph-Attributes.html#SETGAN" title="4.2.2. SETGAN — Set a numeric graph attribute">SETGAN</a></strong></span>(&g, "vertices", <span class="strong"><strong><a class="link" href="igraph-Basic.html#igraph_vcount" title="4.2.1. igraph_vcount — The number of vertices in a graph.">igraph_vcount</a></strong></span>(&g)); |
1926 | 1926 | <span class="strong"><strong><a class="link" href="igraph-Attributes.html#SETGAN" title="4.2.2. SETGAN — Set a numeric graph attribute">SETGAN</a></strong></span>(&g, "edges", <span class="strong"><strong><a class="link" href="igraph-Basic.html#igraph_ecount" title="4.2.2. igraph_ecount — The number of edges in a graph.">igraph_ecount</a></strong></span>(&g)); |
|
1976 | 1976 | } |
1977 | 1977 |
|
1978 | 1978 | <span class="strong"><strong>static</strong></span> void <span class="strong"><strong>simplify_write_destroy</strong></span>(igraph_t *g, igraph_attribute_combination_t *comb) { |
1979 | | - <span class="strong"><strong><a class="link" href="igraph-Operators.html#igraph_simplify" title="3.9. igraph_simplify — Removes loop and/or multiple edges from the graph.">igraph_simplify</a></strong></span>(g, <span class="emphasis"><em>/*remove_multiple=*/</em></span> true, <span class="emphasis"><em>/*remove_loops=*/</em></span> true, comb); |
| 1979 | + <span class="strong"><strong><a class="link" href="igraph-Operators.html#igraph_simplify" title="3.10. igraph_simplify — Removes loop and/or multiple edges from the graph.">igraph_simplify</a></strong></span>(g, <span class="emphasis"><em>/*remove_multiple=*/</em></span> true, <span class="emphasis"><em>/*remove_loops=*/</em></span> true, comb); |
1980 | 1980 | <span class="strong"><strong><a class="link" href="igraph-Foreign.html#igraph_write_graph_graphml" title="3.2. igraph_write_graph_graphml — Writes the graph to a file in GraphML format.">igraph_write_graph_graphml</a></strong></span>(g, stdout, <span class="emphasis"><em>/*prefixattr=*/</em></span> true); |
1981 | 1981 | <span class="strong"><strong><a class="link" href="igraph-Attributes.html#igraph_attribute_combination_destroy" title="3.4. igraph_attribute_combination_destroy — Destroy attribute combination list.">igraph_attribute_combination_destroy</a></strong></span>(comb); |
1982 | 1982 | <span class="strong"><strong><a class="link" href="igraph-Basic.html#igraph_destroy" title="4.1.4. igraph_destroy — Frees the memory allocated for a graph object.">igraph_destroy</a></strong></span>(g); |
|
2055 | 2055 | <pre class="programlisting"><span class="strong"><strong>#include</strong></span> <igraph.h> |
2056 | 2056 |
|
2057 | 2057 | <span class="strong"><strong>static</strong></span> void <span class="strong"><strong>simplify_write_destroy</strong></span>(igraph_t *g, igraph_attribute_combination_t *comb) { |
2058 | | - <span class="strong"><strong><a class="link" href="igraph-Operators.html#igraph_simplify" title="3.9. igraph_simplify — Removes loop and/or multiple edges from the graph.">igraph_simplify</a></strong></span>(g, <span class="emphasis"><em>/*remove_multiple=*/</em></span> true, <span class="emphasis"><em>/*remove_loops=*/</em></span> true, comb); |
| 2058 | + <span class="strong"><strong><a class="link" href="igraph-Operators.html#igraph_simplify" title="3.10. igraph_simplify — Removes loop and/or multiple edges from the graph.">igraph_simplify</a></strong></span>(g, <span class="emphasis"><em>/*remove_multiple=*/</em></span> true, <span class="emphasis"><em>/*remove_loops=*/</em></span> true, comb); |
2059 | 2059 | <span class="strong"><strong><a class="link" href="igraph-Foreign.html#igraph_write_graph_graphml" title="3.2. igraph_write_graph_graphml — Writes the graph to a file in GraphML format.">igraph_write_graph_graphml</a></strong></span>(g, stdout, <span class="emphasis"><em>/*prefixattr=*/</em></span> true); |
2060 | 2060 | <span class="strong"><strong><a class="link" href="igraph-Attributes.html#igraph_attribute_combination_destroy" title="3.4. igraph_attribute_combination_destroy — Destroy attribute combination list.">igraph_attribute_combination_destroy</a></strong></span>(comb); |
2061 | 2061 | <span class="strong"><strong><a class="link" href="igraph-Basic.html#igraph_destroy" title="4.1.4. igraph_destroy — Frees the memory allocated for a graph object.">igraph_destroy</a></strong></span>(g); |
|
4307 | 4307 | </p></td> |
4308 | 4308 | </tr> |
4309 | 4309 | <tr> |
4310 | | -<td><p><span class="term"><em class="parameter"><code>vids</code></em>:</span></p></td> |
| 4310 | +<td><p><span class="term"><em class="parameter"><code>eids</code></em>:</span></p></td> |
4311 | 4311 | <td><p> |
4312 | 4312 | The edges to query. |
4313 | 4313 | </p></td> |
|
0 commit comments