Skip to contents

Keys

The dimoose key object and the ways to build one.

dimoose
A dichotomous key
keyFromSpreadsheet()
Build a key from a spreadsheet
keyFromLeads()
Build a dimoose key from a table of leads
keyFromRpart()
Build a dimoose key from a classification tree
generateTree()
Generate a tree from a feature matrix

Show and share a key

keyDiagram()
Draw a key as a box diagram
exportWizard()
Export an interactive dichotomous key
toNewick()
Write a key as Newick, with safe labels or node annotations
toIgraph()
Convert a key to an igraph directed graph
toTreedata()
Convert a key to a tidytree treedata (for ggtree)
toAuspiceJSON()
Export a key as Auspice (Nextstrain) JSON v2

Example keys and data

sharkKey() arachnidaKey() vibrioKey() montanaKey()
Example keys
montana
Key to the native broadleaf trees of Montana
arachnida
Key to the Orders of Arachnida
vibrio
Vibrio consensus identification matrix
phylotree17
PhyloTree Build 17: the human mitochondrial DNA phylogeny
phylotree17_mutations
PhyloTree Build 17 mutations, one per row
phylotreeKey()
Build an identification key from PhyloTree Build 17

FishBase

importFishbase()
Import a dichotomous key from FishBase
parseFishbase()
Build a dimoose object from FishBase key pages
rawhtml
Raw FishBase key tables

Keys from photos

visionModel()
Load a vision model for embedding images
modelMeta()
Model details as metadata rows
embedImages()
Embed images
embedTexts()
Embed texts
imageSet()
A set of labelled images
imageMeta()
Embed images in a key's metadata
imageMime()
MIME type of an image file from its first bytes
discoverSniglets() discoverTerms()
Discover sniglets by clustering patch embeddings
snigletScores() termScores()
Score images against sniglets
snigletNames()
Names of a key's sniglets
renameSniglets()
Rename sniglets
inventNames()
Invent pronounceable names
keyFromSniglets() keyFromTerms()
Build a key from sniglet scores
vocabularyPrompts()
Prompts for a vocabulary of visual features
keyFromClusters()
Build a key by clustering classes and describing each split
patchExemplars()
Add example crops to a sniglet key
scoreImages()
Score new images against a key's features
featureTable()
A table of machine-computable features
featureScores()
Compute a key's feature scores from embeddings
classify()
Follow a key by machine
evaluateKey()
Accuracy of a key followed by machine
looKey()
Leave-one-out evaluation of a key builder

Keys from sequences and haplogroups

keyFromAlignment()
Build a key from a multiple sequence alignment
alignmentScores()
Score aligned sequences against a key built from an alignment
readHaplogrep()
Read a Haplogrep / PhyloTree tree XML
haplotypeMatrix()
Which mutations each haplogroup carries
macroHaplogroup()
Macrohaplogroup of a haplogroup
recurrentPositions()
Recurrent (homoplasic) mutation sites

Mixed-effects trees

mecit()
Mixed-effects conditional inference trees
keyFromMecit()
Turn a mixed-effects tree into a key
simulateExpression()
Simulate expression data on PhyloTree
splitVariables()
Variables a fitted tree splits on