View Source Bio.Restriction (bio_elixir v0.2.0)
Functions related to restriction enzyme data.
The primary function is digest. The digest function works by recursively
breaking down a binary and checking to see if the pattern for a given enzyme
exists within it.
Note
Currently we don't support enzymes that have two cut sites, or enzymes with ambiguous DNA recognition.
Restriction is also the namespace for Enzyme, where functions for accessing
all the downloaded restriction enzyme data lives. Inside of
Bio.Restriction.Enzyme there is a struct defined. Each method named in the
lowercase fashion of the restriction enzymes returns an instance of this
struct.
The enzyme HpyUM037X is removed from the set, since it has two conflicting entries in the emboss data. If you can resolve this distinction, please feel free to either contribute a fix, or open an issue that explains how one would be implemented.
Link to this section Summary
Functions
Digest takes in a string, anticipated to be a DNA sequence, and extracts the components of the string as a tuple that would remain after digestion with a given restriction enzyme.
Link to this section Functions
Digest takes in a string, anticipated to be a DNA sequence, and extracts the components of the string as a tuple that would remain after digestion with a given restriction enzyme.
examples
Examples
iex> Bio.Restriction.digest("ttagatgacgtctcgattagagt", Bio.Restriction.Enzyme.bsmbi)
["ttagatgacgtctcg", "attagagt"]Currently this will work for enzymes that look back as well:
iex> Bio.Restriction.digest("ggatgcagatcagacgaggattga", Bio.Restriction.Enzyme.bsp143i)
["ggatgc", "agatcagacgaggattga"]It does not yet work on enzymes that would produce digestions with three parts such as NmeDI, nor will it work on enzymes whose recognition pattern is defined using ambiguous DNA (even simply N).