]> git.donarmstrong.com Git - ape.git/blobdiff - src/plot_phylo.c
final changes for ape 2.4 including removing mlphylo!
[ape.git] / src / plot_phylo.c
index a8b1ca3d35b054e559320295958b8d63a44a1e7b..fec2601fa4eb75f0cd9b2f690aca674080eff3dc 100644 (file)
@@ -1,6 +1,6 @@
-/* plot_phylo.c (2006-10-13) */
+/* plot_phylo.c (2009-10-03) */
 
-/* Copyright 2004-2006 Emmanuel Paradis
+/* Copyright 2004-2009 Emmanuel Paradis
 
 /* This file is part of the R-package `ape'. */
 /* See the file ../COPYING for licensing issues. */
@@ -79,3 +79,18 @@ void node_height_clado(int *ntip, int *nnode, int *edge1, int *edge2,
        }
     }
 }
+
+void get_single_index_integer(int *x, int *val, int *index)
+{
+       while (x[*index] != *val) (*index)++;
+       *index += 1;
+}
+
+void get_two_index_integer(int *x, int *val, int *index)
+{
+       while (x[index[0]] != *val) index[0]++;
+       index[1] = index[0] + 1;
+       while (x[index[1]] != *val) index[1]++;
+       index[0] += 1;
+       index[1] += 1;
+}