bionty.Ethnicity

class bionty.Ethnicity(name: str, ontology_id: str | None, abbr: str | None, synonyms: str | None, description: str | None, parents: list[Ethnicity], public_source: PublicSource | None)

Bases: BioRegistry, TracksRun, TracksUpdates

Ethnicity - Human Ancestry Ontology.

Notes

For more info, see tutorials Manage biological registries and Ethnicity.

Bulk create Ethnicity records via from_values.

Examples

>>> record = bionty.Ethnicity.from_public(name="European")
>>> record.save()

Fields

run: Run

Last run that created or updated the record.

id

Internal id, valid only in one DB instance.

uid

A universal id (hash of selected field).

name

Name of the ethnicity.

ontology_id

Ontology ID of the ethnicity.

abbr

A unique abbreviation of ethnicity.

synonyms

Bar-separated (|) synonyms that correspond to this ethnicity.

description

Description of the ethnicity.

public_source

PublicSource this ethnicity associates with.

previous_runs: Run

Sequence of runs that created or updated the record.

parents

Parent ethnicity records.

artifacts

Artifacts linked to the ethnicity.

created_at: datetime

Time of creation of record.

created_by: User

Creator of record.

updated_at: datetime

Time of last update to record.

Methods