API Reference

BioDemuX.BioDemuXModule

BioDemuX: High-performance, flexible demultiplexing for FASTQ files.

Exports the main execute_demultiplexing function and configuration structures.

source
BioDemuX.AbstractScoringType

This function aligns query to ref, using semiglobal alignment algorithm.

Returns

An alignment score as a float, where lower values indicate better alignment.

source
BioDemuX.exact_alignMethod

Aligns query to ref using exact string matching (byte-by-byte comparison). No indels or mismatches allowed. We scan query across ref_search_range in ref. Returns (0.0, start_pos, end_pos) if found, otherwise (Inf, -1, -1).

source
BioDemuX.find_best_matching_bc_no_deltaMethod

Calculate and compare the similarity of a given sequence seq with the sequences in the given DataFrame bc_df.

Returns

A tuple (min_score_bc, min_score, delta, best_start, best_end).

source
BioDemuX.hamming_alignMethod

Aligns query to ref using Hamming distance. Indels are NOT allowed (distance = infinity if lengths differ in an alignment context, but here we scan). We scan query across ref_search_range in ref. N in query matches anything. N in ref matches only N in query. Returns (score, start_pos, end_pos).

source
BioDemuX.match_barcode_passFunction
match_barcode_pass(seq::String, n::Int, config::DemuxConfig, ws::SemiGlobalWorkspace, is_pass2::Bool, stats::Union{DemuxStats,Nothing}=nothing)

Helper function to run a single barcode matching pass. Returns (status, barcode_index, start_pos, end_pos). Status can be: :match, :unknown, :ambiguous.

source
BioDemuX.preprocess_bc_fileMethod
preprocess_bc_file(bc_file::String, complement::Bool, rev::Bool)

Preprocesses the barcode file (FASTA or CSV/TSV). Returns a tuple: (sequences, lengths_no_N, ids).

source
BioDemuX.read_fastqMethod
read_fastq(f::Function, filepath::String)

Open a FASTQ file (potentially gzipped) for reading.

source
BioDemuX.write_fastqMethod
write_fastq(f::Function, filepath::String)

Open a FASTQ file (potentially gzipped) for appending.

source