summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/phylogenetics/PhylogeneticTree.lua
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/phylogenetics/PhylogeneticTree.lua')
-rw-r--r--Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/phylogenetics/PhylogeneticTree.lua46
1 files changed, 23 insertions, 23 deletions
diff --git a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/phylogenetics/PhylogeneticTree.lua b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/phylogenetics/PhylogeneticTree.lua
index 242ccf183ff..f66f2553306 100644
--- a/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/phylogenetics/PhylogeneticTree.lua
+++ b/Master/texmf-dist/tex/generic/pgf/graphdrawing/lua/pgf/gd/phylogenetics/PhylogeneticTree.lua
@@ -29,53 +29,53 @@ local declare = InterfaceToAlgorithms.declare
declare {
key = "phylogenetic tree layout",
algorithm = PhylogeneticTree,
-
+
postconditions = {
upward_oriented = true
},
- summary = [["
- Layout for drawing phylogenetic trees.
+ summary = [["
+ Layout for drawing phylogenetic trees.
"]],
documentation = [["
- ...
+ ...
"]],
examples = [["
- \tikz \graph [phylogenetic tree layout, upgma,
- distance matrix={
- 0 4 9 9 9 9 9
- 4 0 9 9 9 9 9
- 9 9 0 2 7 7 7
- 9 9 2 0 7 7 7
- 9 9 7 7 0 3 5
- 9 9 7 7 3 0 5
- 9 9 7 7 5 5 0}]
- { a, b, c, d, e, f, g };
+ \tikz \graph [phylogenetic tree layout, upgma,
+ distance matrix={
+ 0 4 9 9 9 9 9
+ 4 0 9 9 9 9 9
+ 9 9 0 2 7 7 7
+ 9 9 2 0 7 7 7
+ 9 9 7 7 0 3 5
+ 9 9 7 7 3 0 5
+ 9 9 7 7 5 5 0}]
+ { a, b, c, d, e, f, g };
"]]
}
-
-
+
+
-- Computes a phylogenetic tree and/or visualizes it
-- - computes a phylogenetic tree according to what the "phylogenetic
-- algorithm" key is set to
-- - invokes a graph drawing algorithm according to what the
--- "phylogenetic layout" key is set to
+-- "phylogenetic layout" key is set to
function PhylogeneticTree:run()
-
+
local options = self.digraph.options
-
+
-- Two storages for some information computed by the phylogenetic
- -- tree generation algorithm
+ -- tree generation algorithm
local lengths = Storage.newTableStorage()
-
+
-- First, compute the phylogenetic tree
local tree = options.algorithm_phases['phylogenetic tree generation'].new {
main_algorithm = self,
lengths = lengths
}:run()
-
+
tree = Direct.ugraphFromDigraph(tree)
-
+
-- Second, layout the tree
local layout_class = options.algorithm_phases['phylogenetic tree layout']
layout_class.new {