NAME

Bio::Chado::Schema::Cv::Cvterm

DESCRIPTION

A term, class, universal or type within an ontology or controlled vocabulary. This table is also used for relations and properties. cvterms constitute nodes in the graph defined by the collection of cvterms and cvterm_relationships.

ACCESSORS

cvterm_id

data_type: 'integer'
is_auto_increment: 1
is_nullable: 0
sequence: 'cvterm_cvterm_id_seq'

cv_id

data_type: 'integer'
is_foreign_key: 1
is_nullable: 0

The cv or ontology or namespace to which this cvterm belongs.

name

data_type: 'varchar'
is_nullable: 0
size: 1024

A concise human-readable name or label for the cvterm. Uniquely identifies a cvterm within a cv.

definition

data_type: 'text'
is_nullable: 1

A human-readable text definition.

dbxref_id

data_type: 'integer'
is_foreign_key: 1
is_nullable: 0

Primary identifier dbxref - The unique global OBO identifier for this cvterm. Note that a cvterm may have multiple secondary dbxrefs - see also table: cvterm_dbxref.

is_obsolete

data_type: 'integer'
default_value: 0
is_nullable: 0

Boolean 0=false,1=true; see GO documentation for details of obsoletion. Note that two terms with different primary dbxrefs may exist if one is obsolete.

is_relationshiptype

data_type: 'integer'
default_value: 0
is_nullable: 0

Boolean 0=false,1=true relations or relationship types (also known as Typedefs in OBO format, or as properties or slots) form a cv/ontology in themselves. We use this flag to indicate whether this cvterm is an actual term/class/universal or a relation. Relations may be drawn from the OBO Relations ontology, but are not exclusively drawn from there.

RELATIONS

acquisitionprops

Type: has_many

Related object: Bio::Chado::Schema::Mage::Acquisitionprop

acquisition_relationships

Type: has_many

Related object: Bio::Chado::Schema::Mage::AcquisitionRelationship

analysisfeatureprops

Type: has_many

Related object: Bio::Chado::Schema::Companalysis::Analysisfeatureprop

analysisprops

Type: has_many

Related object: Bio::Chado::Schema::Companalysis::Analysisprop

arraydesign_platformtypes

Type: has_many

Related object: Bio::Chado::Schema::Mage::Arraydesign

arraydesign_substratetypes

Type: has_many

Related object: Bio::Chado::Schema::Mage::Arraydesign

arraydesignprops

Type: has_many

Related object: Bio::Chado::Schema::Mage::Arraydesignprop

assayprops

Type: has_many

Related object: Bio::Chado::Schema::Mage::Assayprop

biomaterialprops

Type: has_many

Related object: Bio::Chado::Schema::Mage::Biomaterialprop

biomaterial_relationships

Type: has_many

Related object: Bio::Chado::Schema::Mage::BiomaterialRelationship

biomaterial_treatments

Type: has_many

Related object: Bio::Chado::Schema::Mage::BiomaterialTreatment

cell_line_cvterms

Type: has_many

Related object: Bio::Chado::Schema::CellLine::CellLineCvterm

cell_line_cvtermprops

Type: has_many

Related object: Bio::Chado::Schema::CellLine::CellLineCvtermprop

cell_lineprops

Type: has_many

Related object: Bio::Chado::Schema::CellLine::CellLineprop

cell_line_relationships

Type: has_many

Related object: Bio::Chado::Schema::CellLine::CellLineRelationship

contacts

Type: has_many

Related object: Bio::Chado::Schema::Contact::Contact

contact_relationships

Type: has_many

Related object: Bio::Chado::Schema::Contact::ContactRelationship

controls

Type: has_many

Related object: Bio::Chado::Schema::Mage::Control

cv

Type: belongs_to

Related object: Bio::Chado::Schema::Cv::Cv

dbxref

Type: belongs_to

Related object: Bio::Chado::Schema::General::Dbxref

cvterm_dbxrefs

Type: has_many

Related object: Bio::Chado::Schema::Cv::CvtermDbxref

cvtermpath_types

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermpath

cvtermpath_objects

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermpath

cvtermpath_subjects

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermpath

cvtermprop_types

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermprop

cvtermprop_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermprop

cvterm_relationship_types

Type: has_many

Related object: Bio::Chado::Schema::Cv::CvtermRelationship

cvterm_relationship_objects

Type: has_many

Related object: Bio::Chado::Schema::Cv::CvtermRelationship

cvterm_relationship_subjects

Type: has_many

Related object: Bio::Chado::Schema::Cv::CvtermRelationship

cvtermsynonym_types

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermsynonym

cvtermsynonym_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermsynonym

dbxrefprops

Type: has_many

Related object: Bio::Chado::Schema::Cv::Dbxrefprop

elements

Type: has_many

Related object: Bio::Chado::Schema::Mage::Element

element_relationships

Type: has_many

Related object: Bio::Chado::Schema::Mage::ElementRelationship

elementresult_relationships

Type: has_many

Related object: Bio::Chado::Schema::Mage::ElementresultRelationship

environment_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Genetic::EnvironmentCvterm

expression_cvterm_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Expression::ExpressionCvterm

expression_cvterm_cvterm_types

Type: has_many

Related object: Bio::Chado::Schema::Expression::ExpressionCvterm

expression_cvtermprops

Type: has_many

Related object: Bio::Chado::Schema::Expression::ExpressionCvtermprop

expressionprops

Type: has_many

Related object: Bio::Chado::Schema::Expression::Expressionprop

features

Type: has_many

Related object: Bio::Chado::Schema::Sequence::Feature

feature_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Sequence::FeatureCvterm

feature_cvtermprops

Type: has_many

Related object: Bio::Chado::Schema::Sequence::FeatureCvtermprop

feature_expressionprops

Type: has_many

Related object: Bio::Chado::Schema::Expression::FeatureExpressionprop

feature_genotypes

Type: has_many

Related object: Bio::Chado::Schema::Genetic::FeatureGenotype

featuremaps

Type: has_many

Related object: Bio::Chado::Schema::Map::Featuremap

featureprops

Type: has_many

Related object: Bio::Chado::Schema::Sequence::Featureprop

feature_pubprops

Type: has_many

Related object: Bio::Chado::Schema::Sequence::FeaturePubprop

feature_relationships

Type: has_many

Related object: Bio::Chado::Schema::Sequence::FeatureRelationship

feature_relationshipprops

Type: has_many

Related object: Bio::Chado::Schema::Sequence::FeatureRelationshipprop

libraries

Type: has_many

Related object: Bio::Chado::Schema::Library::Library

library_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Library::LibraryCvterm

libraryprops

Type: has_many

Related object: Bio::Chado::Schema::Library::Libraryprop

nd_experiments

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdExperiment

nd_experimentprops

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdExperimentprop

nd_experiment_stocks

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdExperimentStock

nd_experiment_stockprops

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdExperimentStockprop

nd_geolocationprops

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdGeolocationprop

nd_protocolprops

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdProtocolprop

nd_protocol_reagents

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdProtocolReagent

nd_reagents

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdReagent

nd_reagentprops

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdReagentprop

nd_reagent_relationships

Type: has_many

Related object: Bio::Chado::Schema::NaturalDiversity::NdReagentRelationship

organismprops

Type: has_many

Related object: Bio::Chado::Schema::Organism::Organismprop

phendescs

Type: has_many

Related object: Bio::Chado::Schema::Genetic::Phendesc

phenotype_assays

Type: has_many

Related object: Bio::Chado::Schema::Phenotype::Phenotype

phenotype_attrs

Type: has_many

Related object: Bio::Chado::Schema::Phenotype::Phenotype

phenotype_observables

Type: has_many

Related object: Bio::Chado::Schema::Phenotype::Phenotype

phenotype_cvalues

Type: has_many

Related object: Bio::Chado::Schema::Phenotype::Phenotype

phenotype_comparison_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Genetic::PhenotypeComparisonCvterm

phenotype_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Phenotype::PhenotypeCvterm

phenstatements

Type: has_many

Related object: Bio::Chado::Schema::Genetic::Phenstatement

phylonodes

Type: has_many

Related object: Bio::Chado::Schema::Phylogeny::Phylonode

phylonodeprops

Type: has_many

Related object: Bio::Chado::Schema::Phylogeny::Phylonodeprop

phylonode_relationships

Type: has_many

Related object: Bio::Chado::Schema::Phylogeny::PhylonodeRelationship

phylotrees

Type: has_many

Related object: Bio::Chado::Schema::Phylogeny::Phylotree

projectprops

Type: has_many

Related object: Bio::Chado::Schema::Project::Projectprop

project_relationships

Type: has_many

Related object: Bio::Chado::Schema::Project::ProjectRelationship

protocols

Type: has_many

Related object: Bio::Chado::Schema::Mage::Protocol

protocolparam_unittypes

Type: has_many

Related object: Bio::Chado::Schema::Mage::Protocolparam

protocolparam_datatypes

Type: has_many

Related object: Bio::Chado::Schema::Mage::Protocolparam

pubs

Type: has_many

Related object: Bio::Chado::Schema::Pub::Pub

pubprops

Type: has_many

Related object: Bio::Chado::Schema::Pub::Pubprop

pub_relationships

Type: has_many

Related object: Bio::Chado::Schema::Pub::PubRelationship

quantificationprops

Type: has_many

Related object: Bio::Chado::Schema::Mage::Quantificationprop

quantification_relationships

Type: has_many

Related object: Bio::Chado::Schema::Mage::QuantificationRelationship

stocks

Type: has_many

Related object: Bio::Chado::Schema::Stock::Stock

stockcollections

Type: has_many

Related object: Bio::Chado::Schema::Stock::Stockcollection

stockcollectionprops

Type: has_many

Related object: Bio::Chado::Schema::Stock::Stockcollectionprop

stock_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Stock::StockCvterm

stockprops

Type: has_many

Related object: Bio::Chado::Schema::Stock::Stockprop

stock_relationships

Type: has_many

Related object: Bio::Chado::Schema::Stock::StockRelationship

stock_relationship_cvterms

Type: has_many

Related object: Bio::Chado::Schema::Stock::StockRelationshipCvterm

studydesignprops

Type: has_many

Related object: Bio::Chado::Schema::Mage::Studydesignprop

studyfactors

Type: has_many

Related object: Bio::Chado::Schema::Mage::Studyfactor

studyprops

Type: has_many

Related object: Bio::Chado::Schema::Mage::Studyprop

studyprop_features

Type: has_many

Related object: Bio::Chado::Schema::Mage::StudypropFeature

synonyms

Type: has_many

Related object: Bio::Chado::Schema::Sequence::Synonym

treatments

Type: has_many

Related object: Bio::Chado::Schema::Mage::Treatment

cvtermprops

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermprop

cvtermsynonyms

Type: has_many

Related object: Bio::Chado::Schema::Cv::Cvtermsynonym

add_synonym

Usage:        $self->add_synonym($synonym , { type => 'exact' , autocreate => 1} );
Desc:         adds the synonym $new_synonym to this cvterm
              If the synonym $new_synonym already exists, 
              nothing is added.
Args:         a synonym name  and
   options hashref as:
         {
           synonym_type => [e.g. exact, narrow, broad, related],
           autocreate => 0,
              (optional) boolean, if passed, automatically create cv,
              cvterm, and dbxref rows if one cannot be found for the
              given synonym name.  Default false.

           cv_name => cv.name to use for the given synonym type.
                      Defaults to 'synonym_type',

           db_name => db.name to use for autocreated dbxrefs,
                      default 'null',

           definitions => optional hashref of:
               { cvterm_name => definition,
               }
            to load into the cvterm table when autocreating cvterms
         }
Ret:          a Cvtermsynonym object
Example:

delete_synonym

Usage: $self->delete_synonym($synonym)
Desc:  delete synonym $synonym from cvterm object
 Ret:  nothing
Args: $synonym
Side Effects: Will delete all cvtermsynonyms with synonym=$synonym. Case insensitive
Example:

get_secondary_dbxrefs

Usage: $self->get_secondary_dbxrefs()
Desc:  find all secondary accessions associated with the cvterm
        These are stored in cvterm_dbxref table as dbxref_ids
Ret:    a list of accessions (e.g. GO:0000123)
Args:   none
Side Effects: none
Example:

add_secondary_dbxref

Usage: $self->add_secondary_dbxref(accession, 1)
Desc:  add an alternative id to cvterm. Stores in cvterm_dbxref
Ret:   a CvtermDbxref object
Args:  an alternative id (i.e. "GO:0001234"). A second arg will store a is_for_definition=1 (default = 0)
Side Effects: stores a new dbxref if accession is not found in dbxref table
Example:

delete_secondary_dbxref

Usage: $self->delete_secondary_dbxref($accession)
Desc:  delete a cvterm_dbxref from the database
Ret:   nothing
Args:  full accession (db_name:dbxref_accession e.g. PO:0001234)
Side Effects:
Example:

create_cvtermprops

Usage: $set->create_cvtermprops({ baz => 2, foo => 'bar' });
Desc : convenience method to create cvterm properties using cvterms
        from the ontology with the given name
Args : hashref of { propname => value, ...},
       options hashref as:
        {
          autocreate => 0,
             (optional) boolean, if passed, automatically create cv,
             cvterm, and dbxref rows if one cannot be found for the
             given cvtermprop name.  Default false.

          cv_name => cv.name to use for the given cvtermprops.
                     Defaults to 'cvterm_property',

          db_name => db.name to use for autocreated dbxrefs,
                     default 'null',

          dbxref_accession_prefix => optional, default
                                     'autocreated:',
          definitions => optional hashref of:
              { cvterm_name => definition,
              }
           to load into the cvterm table when autocreating cvterms
           
           rank => force numeric rank. Be careful not to pass ranks that already exist
                   for the property type. The function will die in such case.

           allow_duplicate_values => default false.
              If true, allow duplicate instances of the same cvterm
              and value in the properties of the cvterm.  Duplicate
              values will have different ranks.
        }
Ret  : hashref of { propname => new cvtermprop object }

create_with

Usage: $schema->resultset('Cv::Cvterm')->create_with(
                 { name   => 'cvterm name',
                   cv     => $cv  || 'cv name',
                   db     => $db  || 'db name',
                   dbxref => $dbx || 'accession',
                 });

Desc: convenience method to create a cvterm, linking it to the CV and
      DB that you name or provide.  For any cv, db, or dbxref that
      you call only by name, does a find_or_create() using that name.
Ret : a new Cvterm row
Args: hashref of:
        { name   => 'cvterm name',
          cv     => 'cv name' or L<Bio::Chado::Schema::Cv::Cvterm> row,
          db     => 'db name' or L<Bio::Chado::Schema::General::Db> row,
          dbxref => 'accession' or L<Bio::Chado::Schema::General::Dbxref> row,
        }