Start here
  • InstallationAdd Nelumbo to a shadcn project
  • ThemingBrand accent, neutrals, dynamic color
  • Biology componentsSequences, maps, plates and trees
  • katalyx.bio

    Sanger Trace

    A chromatogram: the four dye channels as curves, the base calls over their peaks, and each call's quality as a bar, with the ends a trim would cut shaded. It reads .ab1 files as they come off the sequencer.

    Install

    npx shadcn@latest add @nelumbo/sanger-trace

    A read

    A read from the pCAG promoter into mCherry (Biopython's ABIF test file, parsed by parseAbif). The first bases are noisy, as every read's are: their quality bars fall under the Q20 line and the trim shades them. The trace scrolls sideways; hover a peak for the four channels.

    Against a reference

    reference lines the calls up against the bases you expected and marks every difference, with the expected base under the call. This read matches mCherry from its start codon (base 48) to the end of the window; the edited reference shows a one-base change.

    Mixed bases

    mixed flags a call when its second-highest channel reaches that share of the first, as at a heterozygous site. Here, in the read's noisy start, the base caller already wrote some as ambiguity codes (K, Y).

    Open a file

    Choose an .ab1 file to read it here; nothing leaves the page.

    Showing the example read until you open one

    Reading a base

    selectable makes the trace one keyboard stop: arrows move a base (Shift, ten), Page Up and Page Down a screen, Home and End to the ends.

    220bases, 226032_C-ME-18_pCAGseqF

    Props

    PropTypeDefaultNotes
    traces, bases, peaksSangerReadThe four channels, the calls, and the scan of each call's peak: parseAbif gives all three.
    qualitynumber[]Phred quality a call: the bars, the Q20 and Q30 lines, and faded low calls.
    start / rangenumber, { start, end }1, allThe first call's number; a window of the read.
    schemeNucleotideScheme"trace"The channel and call colors.
    height / baseWidthnumber120, 14Curve height; px a base.
    qualityBars / fillbooleantrueThe quality row; a faint fill under the curves.
    trimboolean | numberfalseShade the ends a Mott trim cuts, at an error cutoff of 0.05 or the one given.
    referencestringExpected bases aligned to the calls (- for none): differences are marked.
    mixednumberFlag calls whose second channel reaches this share of the first.
    selectable / onActiveChangeboolean, (base | null) => voidfalseA keyboard stop; the base in focus with its quality and peak heights.
    HelpersparseAbif, qualityTrimAn .ab1 file as a read; the stretch a Mott trim keeps.