Module

Bio.Phylogeny

Package
purescript-phylio
Repository
vibbits/phylio

#Taxa Source

type Taxa = PhylogenyNode

A node in the phylogeny graph.

#Phylogeny Source

newtype Phylogeny

A Phylogeny graph with assocuated metadata. Multiple trees may be stored by their roots.

Constructors

Instances

#Metadata Source

type Metadata = Metadata

Metatdata about a specific phylogeny

#attributes Source

attributes :: Taxa -> Map String Attribute

Get the attribute map for a given Taxa.

#dot Source

dot :: Phylogeny -> String

Generate a GraphViz DOT representation of this phylogeny For more information about DOT see this URL: https://graphviz.org/doc/info/lang.html

#edges Source

edges :: Phylogeny -> Array Edge

Get all edges in a Phylogeny. Note that this includes edges for disconnected trees.

#lookupNode Source

lookupNode :: Phylogeny -> NodeIdentifier -> Maybe PhylogenyNode

Given a Phylogeny and a ref (identifier) get the Taxa for that ref.

#roots Source

roots :: Phylogeny -> Array NodeIdentifier

Get the root for each tree in a Phylogeny.

#parseNewick Source

parseNewick :: String -> Either ParseError Phylogeny

Parse a phylogeny serialised with the Newick format. Some variations of Newick are also supported.

#parseNexus Source

parseNexus :: String -> Either ParseError Phylogeny

Parse a phylogeny serialised with the Nexus format

#parsePhyloXml Source

parsePhyloXml :: String -> Either ParseError Phylogeny

Parse a phylogeny serialised with the PhyloXML format

#reportError Source

reportError :: String -> ParseError -> String

When a ParseError occurs, you can use this function to turn it into a helpful error message. The second argument is the input that failed parsing.

> lmap (parseNewick ")") (reportError ")")
Left ")\n^"

#vertices Source

vertices :: Phylogeny -> Array Taxa

Get all vertices (nodes) in a Phylogeny. Note that this includes vertices from disconnected trees.

#meta Source

meta :: Phylogeny -> Array Metadata

The metadata for each tree in this Phylogeny.

Re-exports from Bio.Phylogeny.Internal.Attributes

#Attribute Source

data Attribute

An Attribute describes some information about a node in the graph. This type represents the structure for storing attributes, not what attributes can be stored.

Constructors

Instances