Skip to content
Snippets Groups Projects
Commit a0bb4e2b authored by Martin Larralde's avatar Martin Larralde
Browse files

Add helper functions to read any format in `lightmotif-io`

parent 197d8059
No related branches found
No related tags found
No related merge requests found
//! Parser implementation for matrices in JASPAR (2016) format.
//! Parser implementation for matrices in JASPAR (raw) format.
//!
//! The [JASPAR database](https://jaspar.elixir.no/docs/) stores manually
//! curated DNA-binding sites as count matrices.
......@@ -114,6 +114,10 @@ impl<B: BufRead> Iterator for Reader<B> {
}
}
pub fn read<B: BufRead>(reader: B) -> self::Reader<B> {
self::Reader::new(reader)
}
#[cfg(test)]
mod test {
......
......@@ -129,6 +129,10 @@ impl<B: BufRead, A: Alphabet> Iterator for Reader<B, A> {
}
}
pub fn read<B: BufRead, A: Alphabet>(reader: B) -> self::Reader<B, A> {
self::Reader::new(reader)
}
#[cfg(test)]
mod test {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment