{"id":19787926,"url":"https://github.com/drostlab/metablastr","last_synced_at":"2025-05-01T00:30:27.015Z","repository":{"id":83417338,"uuid":"74576618","full_name":"drostlab/metablastr","owner":"drostlab","description":"Seamless Integration of BLAST Sequence Searches in R","archived":false,"fork":false,"pushed_at":"2023-09-10T12:42:18.000Z","size":672,"stargazers_count":31,"open_issues_count":7,"forks_count":6,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-06T06:25:07.668Z","etag":null,"topics":["biological-sequences","biomartr","blast","blast-hits","blast-search","blast-searches","blasting","blastn","nucleotide","protein","sequence-diversity","species"],"latest_commit_sha":null,"homepage":"https://drostlab.github.io/metablastr/","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/drostlab.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2016-11-23T12:53:19.000Z","updated_at":"2024-08-22T14:30:32.000Z","dependencies_parsed_at":null,"dependency_job_id":"6b731337-53d0-45c7-821c-da5a1dbd9032","html_url":"https://github.com/drostlab/metablastr","commit_stats":{"total_commits":503,"total_committers":6,"mean_commits":83.83333333333333,"dds":0.4532803180914513,"last_synced_commit":"02dad6daf9f4a0675317177ff434ae9bbcec535f"},"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/drostlab%2Fmetablastr","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/drostlab%2Fmetablastr/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/drostlab%2Fmetablastr/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/drostlab%2Fmetablastr/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/drostlab","download_url":"https://codeload.github.com/drostlab/metablastr/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251802688,"owners_count":21646260,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["biological-sequences","biomartr","blast","blast-hits","blast-search","blast-searches","blasting","blastn","nucleotide","protein","sequence-diversity","species"],"created_at":"2024-11-12T06:25:08.156Z","updated_at":"2025-05-01T00:30:26.512Z","avatar_url":"https://github.com/drostlab.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"# metablastr\n\n## Seamless Integration of [BLAST](https://blast.ncbi.nlm.nih.gov/Blast.cgi) Sequence Searches in R \n\n### Motivation \n\nWith the rapid expansion of available sequences in biological databases, the landscape of modern life science research is being transformed. Currently, around several hundred thousand genomic sequences from a diverse array of species in the tree of life are freely accessible to the public. The R package [biomartr](https://github.com/ropensci/biomartr) enables automated access and retrieval of this vast data, paving the way to delve into the rich tapestry of sequence diversity, uncovering new insights into evolvability, variation, and the emergence of diseases.\n\nThe [biomartr](https://github.com/ropensci/biomartr) package streamlines the retrieval of a massive amount of biological sequence data in a standardized and reproducible manner. Complementing it, the `metablastr` package is tailored to facilitate large-scale sequence searches, also in a standardized and reproducible approach.\n\nIn synergy, [biomartr](https://github.com/ropensci/biomartr) and `metablastr` provide researchers with a comprehensive toolset, allowing them to efficiently gather thousands of biological sequences (genomes, proteomes, annotations, etc.) and conduct extensive sequence comparisons using the gold standard sequence search engine [BLAST](https://blast.ncbi.nlm.nih.gov/Blast.cgi). This facilitates the extraction of novel patterns highlighting similarities and divergences among vast sets of species.\n\nIt's worth noting that the go-to instrument for large-scale sequence searches is BLAST (Basic Local Alignment Search Tool). It is purposefully built to identify regions of sequence similarity between a given query and subject sequences or sequence databases. \n\nBuilding on these advancements, we have recently introduced [DIAMOND2](https://www.nature.com/articles/s41592-021-01101-x), a groundbreaking software solution designed to accelerate `BLAST` searches by an factor of up to 10,000x. To offer researchers even more flexibility and integration, we provide [rdiamond](https://github.com/drostlab/rdiamond), a dedicated interface package that allows programmatic handling of [DIAMOND2](https://github.com/bbuchfink/diamond) sequence searches directly through R. This not only streamlines the sequence search process but also ensures that researchers can access and utilize the power of [DIAMOND2](https://github.com/bbuchfink/diamond) within a familiar R environment.\n\n### Short package description  \n\nThe `metablastr` package harnesses the power of [BLAST](https://blast.ncbi.nlm.nih.gov/Blast.cgi) by providing interface functions between R and the standalone (command line tool) version of this program. \n\nTogether, the `metablastr` package may enable a new level of data-driven genomics\nresearch by providing the computational tools and data science standards needed\nto perform reproducible research at scale.\n\n### Citation\n\n__The `metablastr` package is still under development and not formally published yet. However, we did develop parts of `metablastr` for this Methods chapter which you can cite until a `metablastr` specific manuscript is prepared.__\n\n\u003e M Benoit, HG Drost. [__A Predictive Approach to Infer the Activity and Natural Variation of Retrotransposon Families in Plants__](https://link.springer.com/protocol/10.1007%2F978-1-0716-1134-0_1). In: Cho J. (eds) Plant Transposable Elements. Methods in Molecular Biology, vol 2250. Humana, New York, NY (2021). \n\n\n### Install `metablastr`\n\n### For Linux Users:\n\nPlease install the `libpq-dev` library on you linux machine by typing into the terminal:\n\n```\nsudo apt-get install libpq-dev\n```\n\n### For all systems install `metablastr` by typing\n\n```r\n# install BiocManager if required\nif (!requireNamespace(\"BiocManager\", quietly = TRUE))\n    install.packages(\"BiocManager\")\nBiocManager::install()\n\n# install package dependencies\nBiocManager::install(\n  c(\n    \"Biostrings\",\n    \"GenomicFeatures\",\n    \"GenomicRanges\",\n    \"Rsamtools\",\n    \"IRanges\",\n    \"rtracklayer\")\n)\n\n# install.packages(\"devtools\")\n# install the current version of metablastr on your system\ndevtools::install_github(\"drostlab/metablastr\", build_vignettes = TRUE, dependencies = TRUE)\n```\n\n__Please follow the [Installation Vignette](https://drostlab.github.io/metablastr/articles/installation.html) to install all standalone sequence search tools.__\n\n### Quick start\n \n```r\nlibrary(metablastr)\n# run blastn (nucleotide to nucleotide search) between example query and subject sequences\nblast_test \u003c- blast_nucleotide_to_nucleotide(\n                 query   = system.file('seqs/qry_nn.fa', package = 'metablastr'),\n                 subject = system.file('seqs/sbj_nn.fa', package = 'metablastr'),\n                 output.path = tempdir(),\n                 db.import  = FALSE)\n                 \n# look at BLAST results\nblast_test\n```\n\n```\n   query_id     subject_id perc_identity num_ident_match… alig_length mismatches\n   \u003cchr\u003e        \u003cchr\u003e              \u003cdbl\u003e            \u003cint\u003e       \u003cint\u003e      \u003cint\u003e\n 1 333554|PACi… AT1G01010…          84.2              640         760         63\n 2 333554|PACi… AT1G01010…          84.0              536         638         90\n 3 333554|PACi… AT1G01010…          78.6               44          56         12\n 4 470181|PACi… AT1G01020…          94.7              699         738         39\n 5 470180|PACi… AT1G01030…          95.2             1025        1077         40\n 6 333551|PACi… AT1G01040…          96.0             3627        3779        125\n 7 333551|PACi… AT1G01040…          95.5             1860        1948         82\n 8 909874|PACi… AT1G01050…          96.6              617         639         22\n 9 470177|PACi… AT1G01060…          92.8             1804        1944        110\n10 918864|PACi… AT1G01070…          95.3             1046        1098         40\n# ... with 13 more rows, and 15 more variables: gap_openings \u003cint\u003e,\n#   n_gaps \u003cint\u003e, pos_match \u003cint\u003e, ppos \u003cdbl\u003e, q_start \u003cint\u003e, q_end \u003cint\u003e,\n#   q_len \u003cint\u003e, qcov \u003cint\u003e, qcovhsp \u003cint\u003e, s_start \u003cint\u003e, s_end \u003cdbl\u003e,\n#   s_len \u003cdbl\u003e, evalue \u003cdbl\u003e, bit_score \u003cchr\u003e, score_raw \u003cint\u003e\n```\n\n\n## Discussions and Bug Reports\n\nI would be very happy to learn more about potential improvements of the concepts and functions provided in this package.\n\nFurthermore, in case you find some bugs, need additional (more flexible) functionality of parts of this package, or want to contribute to this project please let me know:\n\nhttps://github.com/drostlab/metablastr/issues\n\n\n## Interfaces implemented in `metablastr`:\n\n### Perform BLAST searches \n\n- `blast_protein_to_protein()`: Perform Protein to Protein BLAST Searches (BLASTP)\n- `blast_nucleotide_to_nucleotide()`: Perform Nucleotide to Nucleotide BLAST Searches (BLASTN)\n- `blast_nucleotide_to_protein()`: Perform Nucleotide to Protein BLAST Searches (BLASTX)\n- `blast_protein_to_nucleotide()`: Perform Protein to Nucleotide BLAST Searches (TBLASTN)\n- `blast_best_hit()`: Retrieve only the best BLAST hit for each query\n- `blast_best_reciprocal_hit()`: Retrieve only the best reciprocal BLAST hit for each query\n- `blast_rpsblast`: Perform Reverse PSI-BLAST searches (rpsblast)\n- `read_blast()`: Import BLAST output into R session (in memory) or via `PostgresSQL` database connection.\n\n### BLAST against common NCBI databases \n\n- `blast_protein_to_nr_database()`: Perform Protein to Protein BLAST Searches against the `NCBI non-redundant database`\n- `blast_nt()`: Perform Nucleotide to Nucleotide BLAST Searches against the `NCBI non-redundant database`\n- `blast_est()`: Perform Nucleotide to Nucleotide BLAST Searches against the `NCBI expressed sequence tags database`\n- `blast_pdb_protein()`:\n- `blast_pdb_nucleotide()`:\n- `blast_swissprot()`:\n- `blast_delta()`:\n- `blast_refseq_rna()`:\n- `blast_refseq_gene()`:\n- `blast_refseq_protein()`:\n\n\n### BLAST against a set of organisms\n\n- `blast_nucleotide_to_genomes()`: Perfrom BLAST Searches Against a Set of Genomes\n- `blast_protein_to_proteomes()`: Perfrom BLAST Searches Against a Set of Proteomes\n- `detect_homologs_cds_to_cds()`: Perform CDS to CDS BLAST Searches against a set of CDS files\n- `detect_homologs_proteome_to_proteome()`: Perform Proteome to Proteome BLAST Searches against a set of Proteomes\n- `extract_hit_seqs_from_genomes()`: Extract sequences of BLAST hits in respective genomes and store it as 'fasta' file(s)\n- `extract_random_seqs_from_genome()`: Extract random loci from a genome of interest\n- `sample_chromosome_intervals()`: Helper function to sample random intervals of length 'interval_width' from chromosomes\n\n### Analyze BLAST Report\n\n- `filter_blast_`:\n\n### Navigation functions\n- `list_outformats()`: List available BLAST output formats\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdrostlab%2Fmetablastr","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdrostlab%2Fmetablastr","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdrostlab%2Fmetablastr/lists"}