Aller au contenu

omnilab/quickgo Référence de l’API

Étage
Fournisseur · Omnilab
Version
1.x
Suite de conformité
non branchée
Vérifié en réel
Son README ne le dit pas
Licence
MIT
composer require omnilab/quickgo:1.x-dev

Lue dans les fichiers PHP du paquet au commit 50564f2cf414 : ses espaces de noms, classes, interfaces et énumérations, leurs constantes, propriétés et méthodes publiques avec leur PHPDoc, et les options que prennent ses fabriques. Rien n’en est exécuté.

Omnilab\QuickGo

  • Annotation class

    One GO annotation of a gene product, as QuickGO gives it: the term, its aspect, the qualifier (enables, involved_in, located_in, part_of, contributes_to, colocalizes_with...; "NOT|" before it for a negative annotation), the evidence (the GO code, IDA; and the ECO term), the reference it rests on (PMID:19740759, GO_REF:0000107), the group that made it and when.

    3 methods · 9 properties

  • QuickGoSource class

    The Gene Ontology through QuickGO, the EBI's browser of GO terms and annotations: a GO term ("GO:0005829", cytosol) - its name, definition, aspect, synonyms, comment, whether it is obsolete, and its direct parents by relation (is_a, part_of, regulates...) -; a UniProt protein ("P68871") with the terms it is annotated to, by aspect, as properties (with their evidence codes) and related things; the annotations themselves (annotations(), outside the contract); a search of terms by text.

    6 methods · 3 constants

  • QuickGoSourceFactory class

    QuickGO: Gene Ontology terms and their parents, the GO annotations of a UniProt protein, a search of terms - no key needed.

    3 options

Omnilab\QuickGo

Annotation class

final readonly class Annotation Annotation.php:16

One GO annotation of a gene product, as QuickGO gives it: the term, its aspect, the qualifier (enables, involved_in, located_in, part_of, contributes_to, colocalizes_with...; "NOT|" before it for a negative annotation), the evidence (the GO code, IDA; and the ECO term), the reference it rests on (PMID:19740759, GO_REF:0000107), the group that made it and when.

public Identifier $term
public ?string $name
public string $aspect
public string $qualifier
public ?string $evidence
public ?string $eco
public ?string $reference
public ?string $assignedBy
public ?\DateTimeImmutable $date

Annotation::__construct()

public function __construct(public Identifier $term, public ?string $name, public string $aspect, public string $qualifier, public ?string $evidence, public ?string $eco, public ?string $reference, public ?string $assignedBy, public ?\DateTimeImmutable $date)

Annotation::fromRow()

public static function fromRow(array $row): ?self
$row

a result of annotation/search

Annotation::isNegative()

public function isNegative(): bool

A negative annotation: the product does NOT do, take part in or sit in the term.

QuickGoSource class

final class QuickGoSource extends HttpSource QuickGoSource.php:34

The Gene Ontology through QuickGO, the EBI's browser of GO terms and annotations: a GO term ("GO:0005829", cytosol) - its name, definition, aspect, synonyms, comment, whether it is obsolete, and its direct parents by relation (is_a, part_of, regulates...) -; a UniProt protein ("P68871") with the terms it is annotated to, by aspect, as properties (with their evidence codes) and related things; the annotations themselves (annotations(), outside the contract); a search of terms by text.

The term's children come with it (related 'child').

No key, no account, no published rate: no throttle by default. Two calls a term (the term, its paths to its aspect's root, which give its direct parents), one a protein (more past 200 annotations), one a search page.

const BASE_URI = 'https://www.ebi.ac.uk/QuickGO/services/'
const MAX_LIMIT = 100

The most terms a search page holds.

const ROOTS = ['molecular_function' => 'GO:0003674', 'biological_process' => 'GO:0008150', 'cellular_component' => 'GO:0005575']

The roots of the three aspects.

QuickGoSource::__construct()

public function __construct(HttpClientInterface $http, readonly int $pages = 5, string $baseUri = self::BASE_URI, array $headers = [], float $throttle = 0.0)
$pages

how many pages of 200 annotations a protein's reading takes at most

QuickGoSource::getName()

public function getName(): string

QuickGoSource::capabilities()

public function capabilities(): array

QuickGoSource::entity()

public function entity(Identifier|string $id): ?Entity

A GO term ("GO:0005829", "GO_0005829", its QuickGO page; a secondary id gives the term it was merged into) or a UniProt protein ("P68871", "uniprot:P68871") with its GO annotations; another base's identifier is refused before any call; null when QuickGO has no such term, or no annotation for that protein.

public function search(Query $query): Page

GO terms whose name or synonyms hold the words, in QuickGO's order; a domain other than biology answers nothing. An entity of a page holds the term's name, definition and aspect: entity() adds its parents.

QuickGoSource::annotations()

public function annotations(Identifier|string $product, ?string $aspect = null): array

The GO annotations of a gene product - a UniProt accession ("P68871") -, every aspect or one ("molecular_function", "biological_process", "cellular_component"), negative ones included (Annotation::isNegative()), in QuickGO's order; at most the configured pages of 200. Outside the contract: an annotation is a statement about two things, with its evidence.

QuickGoSourceFactory class

final class QuickGoSourceFactory extends SourceFactory QuickGoSourceFactory.php:20

QuickGO: Gene Ontology terms and their parents, the GO annotations of a UniProt protein, a search of terms - no key needed.

options: mailto: 'support@glitchr.io' # in the User-Agent annotation_pages: 5 # pages of 200 annotations a protein's reading takes at most throttle: 0 # seconds between two calls: QuickGO publishes no rate base_uri: 'https://www.ebi.ac.uk/QuickGO/services/'

Options

OptionDefault
annotation_pages5
throttle0.0
base_uriQuickGoSource::BASE_URI