haps_phylo {jackalope} | R Documentation |
Organize information to create haplotypes using phylogenetic tree(s)
Description
This function organizes higher-level information for creating haplotypes from
phylogenetic tree(s) output as phylo
or multiPhylo
objects
(both from the ape
package) or NEWICK files.
Note that all phylogenetic trees must be rooted and binary.
If using this function, I encourage you to cite ape
. For citation
information, see output from citation("ape")
.
Usage
haps_phylo(obj = NULL, fn = NULL)
Arguments
obj |
Object containing phylogenetic tree(s).
This can be (1) a single |
fn |
One or more string(s), each of which specifies the file name
of a NEWICK file containing a phylogeny.
If one name is provided, that phylogeny will be used for all chromosomes.
If more than one is provided, there must be a phylogeny for each reference
genome chromosome, and phylogenies will be assigned to chromosomes
in the order provided.
Defaults to |
Details
See ?ape::write.tree
for writing phylogenies to an output file.
Value
A haps_phylo_info
object containing information used in create_haplotypes
to create variant haplotypes.
This class is just a wrapper around a list containing phylogenetic tree
information for each reference chromosome, which you can view (but not change)
using the object's phylo()
method.