BP_INDEX(1p)

πŸ“¦
version 1.7.8 Β· 3 versions
, in debian bookworm, debian trixie, ubuntu jammy, ubuntu noble

πŸ‘‘ BP_INDEX(1p) β€” aka bp_index.pl πŸ’…

okay bestie, sit down, we're learning bp_index.pl today and honestly? it's giving utility. the manual page is BP_INDEX(1p) and the whole thing is about indexing files for use by bp_fetch.pl. that's the vibe. ✨


🌸 NAME 🌸

bp_index.pl β€” indexes files for use by bp_fetch.pl

like, it makes the index. the fetch does the fetching. girlboss / malewife energy, they're a duo. 🫢


✨ SYNOPSIS ✨

bp_index.pl index_name file1 file2 etc.

you give it a name for the index, then you throw files at it. that's it. that's the whole thing. πŸŽ€


πŸ’– DESCRIPTION πŸ’–

so bp_index.pl builds a bioperl index for the sequence files you list in the argument list, and it files that index under the index name you gave it. iconic behaviour, honestly.

for example:

bp_index.pl nrdb /data/nrdb/nrdb.fasta

that would build an index called 'nrdb' as the index name for the file nrdb.fasta. so cute, so simple. πŸ’…

and then:

bp_index.pl -fmt EMBL swiss /data/swiss/*.dat

would build an index called swiss for all the files in /data/swiss which end in .dat which are in EMBL format. shell globbing girlies rise up πŸ¦‹

the indexes are built using the Bio/Index/* modules β€” in particular, Bio::Index::EMBL and the Bio::Index::Fasta modules. any script which uses these modules can use the index. a good example script is bp_fetch which fetches sequences and pipes them to STDOUT, for example:

bp_fetch swiss:ROA1_HUMAN

gets the ROA1_HUMAN sequence from the swiss index and writes it as fasta format on STDOUT. no cap. πŸ”₯


πŸŽ€ OPTIONS πŸŽ€

  • -fmt <format> β€” Fasta (default), swiss or EMBL. pick your format bestie, but the default is Fasta.
  • -dir <dir> β€” directory where the index files are found (overrides the BIOPERL_INDEX environment variable).

options for expert use πŸ‘‘

  • -type <db_type> β€” DBM_file type. (overrides the BIOPERL_INDEX_TYPE environment variable)
  • -v β€” report every index addition (debugging). she's loud, she's thorough, she's for debugging. πŸ—£οΈ

🌈 ENVIRONMENT 🌈

bp_index and bp_fetch coordinate where the databases lie using the environment variable BIOPERL_INDEX. this can be overridden using the -dir option. there is no default value, so you must use the -dir option or set BIOPERL_INDEX. πŸ’€

fr fr, if you skip both, nothing is gonna happen the way you want. use -dir or set BIOPERL_INDEX, periodt.

the DB type is coordinated with BIOPERL_INDEX_TYPE which, if it is not there, defaults to whatever the bioperl modules have installed, which itself defaults to SDBM_File. layers on layers, it's giving onions. πŸ§…


πŸ’œ USING IT YOURSELF πŸ’œ

bp_index.pl is a script that drives the Index modules. if you want to use this script heavily in your work β€” if it is Perl based β€” it is almost certainly better to look at the code in this script and copy it across (probably you will be more likely to want to use the bp_fetch code). read the source bestie, it's right there. πŸ‘€


⭐ EXTENDING IT ⭐

bp_index is just a wrapper around James Gilbert's excellent Index modules found in bioperl. respect the OG. 🫑


πŸ¦‹ FEEDBACK πŸ¦‹

πŸ’Œ Mailing Lists

user feedback is an integral part of the evolution of this and other Bioperl modules. send your comments and suggestions preferably to the Bioperl mailing list. your participation is much appreciated. πŸ₯Ή

bioperl-l@bioperl.org                  - General discussion
http://bioperl.org/wiki/Mailing_lists  - About the mailing lists

πŸ› Reporting Bugs

report bugs to the Bioperl bug tracking system to help us keep track of the bugs and their resolution. bug reports can be submitted via the web:

https://github.com/bioperl/bioperl-live/issues

πŸ‘‘ AUTHOR - Ewan Birney πŸ‘‘

Ewan Birney <birney@ebi.ac.uk>


and that's the whole page, bestie!! mwah πŸ’– this one came from perl v5.32.1, dated 2021-08-15, and it lives in the manual as BP_INDEX(1p). go build an index, you absolute main character. πŸŽ€βœ¨

πŸ“¦ where this page comes from