Recore Recore
For Panaroo, Roary, PPanGGOLiN, PanTA and PIRATE

Missing from the matrix. Still in the genome.

Recore searches every empty cell of a pangenome matrix in the assemblies, puts back the genes that are really there, and keeps the evidence for each one.

Reads your pangenome and the assemblies. Writes a corrected matrix and a report. Never edits your files.

Genes across, genomes down. Point at a cell. Input matrix
present put back kept out, with the reason absent
0put back
0kept out (pseudogenes)
0really absent
1

Install

Two commands. Recore uses minimap2 to search.

minimap2
$ conda install -c bioconda minimap2
Recore
$ cargo install --git https://github.com/PathoGenOmics-Lab/recore --locked

Needs Rust 1.85 or newer (rustup.rs), about a minute to build. Check with recore --version. The source is on GitHub.

2

Your command

Pick what you have. Copy the command.

Which tool made your pangenome?

What else do you have?
How should it run?
    3

    Or try it first

    Twelve genomes with eleven false absences planted in them. About a minute.

    $ curl -sO https://raw.githubusercontent.com/PathoGenOmics-Lab/recore/main/benchmarks/make_tutorial_dataset.py
    $ python3 make_tutorial_dataset.py --out tutorial_data
    $ recore -p tutorial_data/gene_presence_absence.csv \
             -r tutorial_data/pan_genome_reference.fa \
             -g tutorial_data/genomes -a tutorial_data/annotations --synteny \
             --tree tutorial_data/species.tree --write-html-report -o tutorial_out
    tutorial_out/summary.txt Rescued: 11 every planted absence found Matrix-corrected: 8 the other 3 are pseudogenes: kept out, with the reason

    Then open tutorial_out/recore_report.html. Want the story behind each number? Read the walkthrough.

    4

    What you get

    Four files answer most questions. See all of them.

    gene_presence_absence_recore.csv

    The corrected matrix, in the input's format (and as .Rtab). Feed it to your next tool.

    gene_presence_absence_recore_states.csv

    The same matrix with a state in every cell: input, put back, kept out and why. For figures.

    orthology_evidence.tsv

    One row per change: the evidence, the decision, and wording you can use in a paper.

    recore_report.html

    The whole run in one page that works offline. Open it in any browser.

    5

    Explore the report

    This one comes from the example run, on synthetic data: twelve made-up genomes with eleven planted absences. Click around.

    recore_report.htmlsynthetic dataOpen full screen ↗

    The report is made for a large screen. This one is the example run's, on synthetic data.

    Open it full screen ↗
    Hover a cellfor the evidence behind it; click it for the whole row.
    Search a genein the box at the top, or press ? for every shortcut.
    Follow the treeon the left: genomes are drawn in phylogeny order.
    6

    One setting that matters

    --matrix-policy picks which evidence reaches the corrected matrix. All of it stays in the audit files.

    Ten genes Recore found where the matrix said absent. Pick a policy:
    Same locus, by annotation or by its neighbours
    Full-length gene, found by sequence
    Partial copy or pseudogene
    Neighbours disagree, or it is a paralog

    ?

    If something looks off

    The questions people ask first.

    It says minimap2 was not found

    Recore runs minimap2 for every search. Install it (step 1) and check that minimap2 --version works in the same terminal.

    It finds no genome files, or no GFF matches a genome

    Name each file after its column in the matrix: column L1_AS00101 reads genomes/L1_AS00101.fasta and annotations/L1_AS00101.gff. FASTA can end in .fasta, .fa or .fna, GFF in .gff or .gff3, gzipped or not.

    It rescued nothing

    Read the Gaps: line of the log. Genes in fewer than 10% of genomes are not searched; --min-prevalence 0 searches them all. Check the file names (above), and use --preset asm20 for divergent species.

    Will it change my matrix or my GFFs?

    No. It reads them and writes everything new into the output folder, recore_output/ unless you pass -o.

    How long does it take, and how much memory?

    800 genomes of 4.9 Mb take about 20 seconds on a laptop with 8 threads and about half a gigabyte of memory, which grows by about 0.5 MB per genome. The measurements.

    Can I try another policy without searching again?

    Yes. Add --search-cache cache/ to both runs: the second one aligns only what changed.

    How do I describe it in a paper?

    For the default policy: We used Recore with the balanced matrix policy, which rescues full-length false absences while retaining partial or disrupted homologues as multistate audit-only evidence.

    Open source, on GitHub

    Read the code, follow the releases, ask a question or report a bug.