EVOLUTION-MANAGER
Edit File: consensus_tree.html
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><title>R: Create a consensus tree from several hierarchical random...</title> <meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> <link rel="stylesheet" type="text/css" href="R.css" /> </head><body> <table width="100%" summary="page for consensus_tree {igraph}"><tr><td>consensus_tree {igraph}</td><td style="text-align: right;">R Documentation</td></tr></table> <h2>Create a consensus tree from several hierarchical random graph models</h2> <h3>Description</h3> <p><code>consensus_tree</code> creates a consensus tree from several fitted hierarchical random graph models, using phylogeny methods. If the <code>hrg</code> argument is given and <code>start</code> is set to <code>TRUE</code>, then it starts sampling from the given HRG. Otherwise it optimizes the HRG log-likelihood first, and then samples starting from the optimum. </p> <h3>Usage</h3> <pre> consensus_tree(graph, hrg = NULL, start = FALSE, num.samples = 10000) </pre> <h3>Arguments</h3> <table summary="R argblock"> <tr valign="top"><td><code>graph</code></td> <td> <p>The graph the models were fitted to.</p> </td></tr> <tr valign="top"><td><code>hrg</code></td> <td> <p>A hierarchical random graph model, in the form of an <code>igraphHRG</code> object. <code>consensus_tree</code> allows this to be <code>NULL</code> as well, then a HRG is fitted to the graph first, from a random starting point.</p> </td></tr> <tr valign="top"><td><code>start</code></td> <td> <p>Logical, whether to start the fitting/sampling from the supplied <code>igraphHRG</code> object, or from a random starting point.</p> </td></tr> <tr valign="top"><td><code>num.samples</code></td> <td> <p>Number of samples to use for consensus generation or missing edge prediction.</p> </td></tr> </table> <h3>Value</h3> <p><code>consensus_tree</code> returns a list of two objects. The first is an <code>igraphHRGConsensus</code> object, the second is an <code>igraphHRG</code> object. The <code>igraphHRGConsensus</code> object has the following members: </p> <table summary="R valueblock"> <tr valign="top"><td><code>parents</code></td> <td> <p>For each vertex, the id of its parent vertex is stored, or zero, if the vertex is the root vertex in the tree. The first n vertex ids (from 0) refer to the original vertices of the graph, the other ids refer to vertex groups.</p> </td></tr> <tr valign="top"><td><code>weights</code></td> <td> <p>Numeric vector, counts the number of times a given tree split occurred in the generated network samples, for each internal vertices. The order is the same as in the <code>parents</code> vector.</p> </td></tr> </table> <h3>See Also</h3> <p>Other hierarchical random graph functions: <code><a href="fit_hrg.html">fit_hrg</a>()</code>, <code><a href="hrg-methods.html">hrg-methods</a></code>, <code><a href="hrg_tree.html">hrg_tree</a>()</code>, <code><a href="hrg.html">hrg</a>()</code>, <code><a href="predict_edges.html">predict_edges</a>()</code>, <code><a href="print.igraphHRGConsensus.html">print.igraphHRGConsensus</a>()</code>, <code><a href="print.igraphHRG.html">print.igraphHRG</a>()</code>, <code><a href="sample_hrg.html">sample_hrg</a>()</code> </p> <hr /><div style="text-align: center;">[Package <em>igraph</em> version 1.3.5 <a href="00Index.html">Index</a>]</div> </body></html>