Skip to main content

biogeoloc

A python object package for storing and managing geographic information about biological samples

Installation

pip install biogeoloc

Example

  1. Accession

Accession objects are used to store information about a biological sample. This information includes the sample's geographic location, the date it was collected, and any other relevant information.

There are three main information types that can be stored in an Accession object:

  • Coordinates: The geographic location of the sample
  • IDs: You can store different types of IDs for the sample
  • passport: Information about the sample, such as the date it was collected, the collector, and any other relevant information
  • phenotypic: Information about the sample's phenotype
  • dataset: Information about the dataset the sample belongs to
  • properties: Any other relevant information about the sample
from biogeoloc import Accession

acc = Accession('u0001', genesys_id='23412', pi_id=['PI628326', 'PI326387'], lib_id='333', latitude=12.345, longitude=23.456, dataset={'reseq': True})
  1. AccessionSet

AccessionSet objects are used to store multiple Accession objects. This is useful when you have a collection of samples that you want to manage together.

from biogeoloc import AccessionSet

acc1 = Accession('xyx1', lat=1.0, lon=2.0, alt=3.0, lib_id='lib1', pi_id='pi1')
acc2 = Accession('xyx2', lat=1.0, lon=2.0, lib_id='lib2', pi_id_list=['pi2', 'pi3'], is_id_list=['is2', 'is3'])
acc3 = Accession('xyx3', is_id='is3', lib_id='lib3', pi_id='pi3')

AS = AccessionSet('test', '2020-01-01',
                    default_ID_items={'lib_id': str, 'pi_id': list, 'is_id': list})
AS.add(acc1)
AS.add(acc2)
AS.add(acc3)

AS.build_index()

uniq_id = AS.search('lib1', 'lib_id')
acc = AS.get(uniq_id)

print(vars(acc))
  1. GeneSys

GeneSys objects are used to parse and store information from the Genesys database. This is useful when you want to access information about a sample from the Genesys database.

Go to GeneSys Website to download the accessions data in a zip file. Extract the zip file and use the GeneSys object to parse the data.

from biogeoloc import GeneSys

download_genesys_dir = '/path/to/downloaded/genesys/data'
sorghumGS = GeneSys()
sorghumGS.load(download_genesys_dir)
sorghumGS.build_index()

q_id = 'PI207841'
u_id = sorghumGS.search(q_id)
acc = sorghumGS.get(u_id)

Metadata

Release files for biogeoloc 0.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for biogeoloc 0.0.4
File Size Uploaded Provenance
biogeoloc-0.0.4.tar.gz 12.3 kB Without provenance Details

Built distribution (wheel)

Table of built distributions (wheels) for biogeoloc 0.0.4
File Interpreter ABI Platform
biogeoloc-0.0.4-py3-none-any.whl Python 3 none any Details

Total release size: 24.3 kB

Release files / biogeoloc-0.0.4.tar.gz

Download URL biogeoloc-0.0.4.tar.gz
Size 12.3 kB
Tags Source
SHA-256 checksum
How to use checksums
0b64501eedab661d758407e666a0f2c1852a83d1eb5993708949ec90d768dd6e
BLAKE2b-256 checksum
How to use checksums
28eb0f8d5e2c4c0598a34c1fd1d98dd2f879bc5b3df520ea0df2d3bf7b8ef3e3
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.13

Release files / biogeoloc-0.0.4-py3-none-any.whl

Download URL biogeoloc-0.0.4-py3-none-any.whl
Size 12.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
358028347d227f7e20f70583f9cff7d19fda8bf3af0fe5e2e0040e7eb4413169
BLAKE2b-256 checksum
How to use checksums
a95d5d1f3b15b1a9a5ecc32ae41783f3bd4c08220f0bc86435a46344251ed108
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.13

Security for biogeoloc 0.0.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page