Skip to content

Commit 7ba0943

Browse files
committed
Add top level docs
1 parent 663f11d commit 7ba0943

9 files changed

+14
-1
lines changed

src/distances.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! Functions and traits for calculating and storing distances
12
use std::cmp::Ordering;
23
use std::fmt;
34

src/hashing/mod.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! [nthash](https://github.com/bcgsc/ntHash[) and [aahash](https://github.com/bcgsc/ntHash) iterators
12
use clap::ValueEnum;
23
use serde::{Deserialize, Serialize};
34

src/io.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! Functions to read input fasta/fastq files
12
use std::fs::File;
23
use std::io::{stdout, BufRead, BufReader, BufWriter, Write};
34
use std::path::Path;

src/jaccard.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! Implementation of Jaccard, core and accessory distance calculations
12
use crate::multisketch::MultiSketch;
23
use crate::sketch::BBITS;
34

src/lib.rs

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
1-
//! DOCS
1+
//! Fast distance calculations between biological sequences (DNA, AA or structures
2+
//! via the 3di alphabet). Distances are based on bindash approximations of the Jaccard
3+
//! distance, with the PopPUNK method to calculate core and accessory distances. nthash/aahash
4+
//! are used for hash functions to create the sketches
25
//!
6+
//! This package is a work in progress, but is mature enough for research use. See README.md
7+
//! for current CLI usage.
38
49
// #![warn(missing_docs)]
510

src/multisketch.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! The class to support .skm/.skd reading and writing, containing multiple [`Sketch`] objects
12
use anyhow::bail;
23
use anyhow::Error;
34
use anyhow::{Result, anyhow};

src/sketch.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! Methods to create single sample's sketch
12
use std::cmp::Ordering;
23
use std::fmt;
34
use std::sync::mpsc;

src/sketch_datafile.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! I/O support and memory mapping used by for lower level read/write to .skd
12
use memmap2::Mmap;
23
use std::error::Error;
34
use std::fs::File;

src/structures.rs

+1
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
//! Support for .pdb files and the 3di alphabet
12
use anyhow::Error;
23
use crate::io::InputFastx;
34

0 commit comments

Comments
 (0)