performAccessionSearch: Perform an Accession Search

View source: R/accessionSearch.R

performAccessionSearchR Documentation

Perform an Accession Search

Description

Search the provided Accession Search Database to find database terms that match the provided search terms.

Usage

performAccessionSearch(
  db,
  terms,
  config = getBBOption("accession_search_config")
)

Arguments

db

Accession Search Database

terms

Vector of accession search terms

config

Accession Search Configuration

Details

The accession search can be configured by providing a set of accession search configuration properties, which is a nested list with the following names:

NAME DEFINITION DEFAULT VALUE
database_terms a list with the names: name, synonyms, accession_numbers
database_terms$name flag to include accession names in the accession search TRUE
database_terms$synonyms flag to include accession synonyms in the accession search TRUE
database_terms$accession_numbers flag to include the accession numbers in the accession search TRUE
search_routines a list with the names: exact, punctuation, substring, prefix, edit_distance
search_routines$exact flag to use the exact name search routine in the accession search TRUE
search_routines$punctuation flag to use the punctuation search routine in the accession search TRUE
search_routines$substring flag to use the substring search routine in the accession search TRUE
search_routines$prefix flag to use the prefix search routine in the accession search FALSE
search_routines$edit_distance flag to use the edit distance search routine in the accession search FALSE
search_routine_options a list that has names of the supported search routines with values set as a list of the search routine options
search_routine_options$substring$substring_length_min the minimum length of a term to be included as a substring match 3
search_routine_options$prefix$prefixes default prefixes to include []
search_routine_options$prefix$find_db_prefixes scan the database terms to find common prefixes TRUE
search_routine_options$prefix$prefix_length_min when finding db prefixes, the minimum length of a prefix to include 2
search_routine_options$prefix$prefix_length_max when finding db prefixes, the maximum length of a prefix to include 5
search_routine_options$prefix$threshold when finding db prefixes, the minimum number of times a prefix is used before it is included 250
search_routine_options$edit_distance$max_edit_distance the maximum number of changes for the edit distance comparison 2
case_sensitive flag to perform a case-sensitive search TRUE
return_records flag to include the germplasm records with the search results FALSE

Value

a tibble containing the search results. Example:

search_term search_routine germplasm_name germplasm_id database_term database_term_type
jerry Exact Match JERRY 230227 JERRY name
SY-Gold Exact Match 00X0100-51 232633 Sy-Gold synonym
PU0128A1_36 Remove Punctuation 0218A1-36 238801 PU0128A1-36 synonym

See Also

Other accessionSearch: createAccessionSearchDB(), getAccessionSearchCacheStatus(), getAccessionSearchConfig(), getAccessionSearchDB(), getAccessionSearchDBs(), getAccessionSearchServer(), updateAccessionSearchCache()


TriticeaeToolbox/breedbase.R documentation built on Aug. 8, 2024, 7:15 a.m.