<commit_before><?xml version="1.0"?>
<!-- -*- DocBook -*- -->

<article>

<index>


   <section>
       <heading>The FlyMine Data Model</heading>
       <item>The FlyMine database is based upon an object model.  The object model has been created by merging existing ontologies and standards including the Sequence Ontology, MAGE, and PSI (blah blah). Additional FlyMine specific classes help link the ontologies and provide classes relating to the evidence for a particular piece of data (needs work!!).  To get the most out of querying FlyMine it is useful to understand a bit about the underlying data model.  First of all it is useful to understand the concepts of classes, objects and fields.</item>
    </section>


   <section>
        <heading>Classes, Objects and Fields - the basics</heading>
        <item>Classes can be thought of as templates to describe information about a specific type of thing. Things which have similar properties belong to the same class.  For example in FlyMine there is a 'Gene' class.  The Gene class describes properties of genes.  The actual properties are known as fields.  The class is a holder for a set of fields that provide information about the 'thing'.  For example the Gene class has the fields name, seqlength (sequence length), residues etc.  An object is an actual member of a class (known as an 'instance' of that class). For example, the Notch gene is a member of the gene class. Every object of a class has the set of properties (fields) that describe that class, although some of these fields may be empty (ie there may not be any data available for some fields).</item>
        <item>An easier way to understand classes and objects is to think of a company database.  A company database can have classes that represent, for example, employees and departments.  The employees class could be further subdivided into more specilazed classes representing certain types of employee, eg director, manager. Each class is described by certain information.  For example, the employee class can be described by the fields, name, age and wage.  A particular employee, eg Eric, is an object (or instance) of the employee class.  Classes can have relationships to each other.  For example, the employee class can have a relationship to the department class, as employees belong to departments.  A particular instance of the employee class has a relationship to a particular instance of the department class,  eg Eric may be in the Genetics department. In the FlyMine model, a specific object within a class has a relationship with a specific object in another class.  For example, there is a relationship between the Gene class and the Transcript class. In practise this actually means that individual objects of the Gene class have a relationship with specific objects within the transcripts class.  i.e a particular gene object has particular transcripts.</item>
         <item>You can also think of the classes as boxes containing lots of individual items (objects).  To create a query you want certain items from a certain number of boxes.  You therefore have to select the boxes that require the items you want and constrain the boxes so that you only select the subset of items in the boxes that you require.  Because of the relationships between the objects in the boxes you may only need to constrain one box to retrieve a subset of items form another box.  eg if you want all the genes from Drosophila, you only need to constrain the organism class to Drosophila to retrieve that subset of genes from the gene class.</item>
         <item>Fields can be one of several different data types.  For example some fields simply contain one piece if information, such as a name.  In this case the field is the type 'string'.  Similarly, fields that contain just a number will be of the type, integer or ??????.  Fields that contain a list of objects are know as collections. Some fields are actually references (pointers) to other classes (explained in more detail below). (fields containing collections from other classes?????)</item>
    </section>


   
	  <entry>
	      <inlinegraphic fileref="classDiag2.gif" format="GIF"/>
	  </entry>
  





    <section>
         <heading>FlyMine Classses, objects and fields</heading>
        <item>The FlyMine object model is made up of a number of classes which are linked together through various relationships.  For example, the gene class is directly linked to the transcripts class, which has a link to a translation class.</item>
    </section>

    <section>
          <heading>Applying Constraints</heading>
           <item>Querying FlyMine involves selecting and combining the classes that hold the objects you require.  Constraints can be applied to the objects contained in a class, so that only a certain subset of those objects which have the required characteristics are selected.  For example the gene class contains a large number of genes (gene objects) from all the organisms represented in FlyMine.  However you may only be interested in data related to one specific gene.  You would therefore constrain the gene name field of the gene class to that of the required gene.  If you wish to know about the transcripts of that gene you would combine information from the gene class and the transcripts class.  By constraining the name field of the gene class to a particular gene, you will only retrieve infomation from the transcripts class that relates to that gene  (ie you do not need to apply the constraint to the transcripts class as well).  This is because that particular gene object has a relationship to particular objects (instances) of the transcript class  (ie those transcripts that are produced from that particular gene).</item>
      </section>



   
	  <entry>
	      <inlinegraphic fileref="constrainDiag1.gif" format="GIF"/>
	  </entry>
  






    <section>
      <heading>The FlyMine model Browser</heading>
          <item>The FlyMine model browser allows you to select the classes that contain the objects you require. Depending on the starting class you will be able to navigate to other classes as defined by the relationships between the classes.  In other words, to combine classes containing the objects you require, you find a path though the classes that link together the information you require. Within the model browser classes that can be accessed from a parent class (ie are linked to the parent class through a relationship) are shown as fields within that class (actaully a reference field, as the field is a reference to that particular class).   For example, there is a relationship between the gene class and the Transcript class.  The Transcript class therefore appears as a field within the gene class. </item>
           <item>STUFF ABOUT CONSTRAINING, SHOW AND THE DIFFERENCE BETWEEN SELECTING FIELDS AND CLASSES TO SHOW.</item>
     </section>


   
	  <entry>
	      <inlinegraphic fileref="classes.gif" format="GIF"/>
	  </entry>
  

<commit_msg>*** empty log message ***<commit_after><?xml version="1.0"?>
<!-- -*- DocBook -*- -->

<article>

<index>


   <section>
       <heading>The FlyMine Data Model</heading>
       <item>
The FlyMine database is based upon an object model.  The object model
has been created by merging existing ontologies and standards
including the Sequence Ontology, MAGE, and PSI (blah blah). Additional
FlyMine specific classes help link the ontologies and provide classes
relating to the evidence for a particular piece of data (needs
work!!).  To get the most out of querying FlyMine it is useful to
understand a bit about the underlying data model.  First of all it is
useful to understand the concepts of classes, objects and fields.
</item>
    </section>


   <section>
        <heading>Classes, Objects and Fields - the basics</heading>
        <item>Classes can be thought of as templates to describe information about a specific type of thing. Things which have similar properties belong to the same class.  For example in FlyMine there is a 'Gene' class.  The Gene class describes properties of genes.  The actual properties are known as fields.  The class is a holder for a set of fields that provide information about the 'thing'.  For example the Gene class has the fields name, seqLen (sequence length), residues etc.  An object is an actual member of a class (known as an 'instance' of that class). For example, the Notch gene is a member of the gene class. Every object of a class has the set of properties (fields) that describe that class, although some of these fields may be empty (ie. there may not be any data available for some fields).</item>
        <item>An easier way to understand classes and objects is to think of a company database.  A company database can have classes that represent, for example, employees and departments.  The employees class could be further subdivided into more specialised sub-classes representing certain types of employee, eg director, manager. Each class is described by certain information.  For example, the employee class can be described by the fields, name, age and wage.  A particular employee, eg. Eric, is an object (or instance) of the employee class.  Classes can have relationships to each other.  For example, the employee class can have a relationship to the department class, as employees belong to departments.  A particular instance of the employee class has a relationship to a particular instance of the department class,  eg. Eric may be in the Genetics department. In the FlyMine model, a specific object within a class has a relationship with a specific object in another class.  For example, there is a relationship between the Gene class and the Transcript class. In practise this actually means that individual objects of the Gene class have a relationship with specific objects within the transcripts class.  ie. a particular gene object has particular transcripts.</item>
         <item>You can also think of the classes as boxes containing lots of individual items (objects).  To create a query you want certain items from a certain number of boxes.  You therefore have to select the boxes that require the items you want and constrain the boxes so that you only select the subset of items in the boxes that you require.  Because of the relationships between the objects in the boxes you may only need to constrain one box to retrieve a subset of items form another box.  eg if you want all the genes from Drosophila, you only need to constrain the organism class to Drosophila to retrieve that subset of genes from the gene class.</item>
         <item>Fields can be one of several different data types.  For example some fields simply contain one piece if information, such as a name.  In this case the field is the type 'string'.  Similarly, fields that contain just a number will be of the type, integer or ??????.  Fields that contain a list of objects are know as collections. Some fields are actually references (pointers) to other classes (explained in more detail below). (fields containing collections from other classes?????)</item>
    </section>


   
	  <entry>
	      <inlinegraphic fileref="classDiag2.gif" format="GIF"/>
	  </entry>
  





    <section>
         <heading>FlyMine Classes, objects and fields</heading>
        <item>The FlyMine object model is made up of a number of classes which are linked together through various relationships.  For example, the gene class is directly linked to the transcripts class, which has a link to a translation class.  A number of classes are subdivided into more specialized sub-classes.  E.g. the Transcript class is subdivided into Primary Transcripts, Processed Transcripts etc.  The Exon class is subdivided into 5' exon, 3' exon etc.</item>
    </section>

    <section>
          <heading>Constraining</heading>
           <item>Querying FlyMine involves selecting and combining the classes that hold the objects you require.  Constraints can be applied to the objects contained in a class, so that only a certain subset of those objects which have the required characteristics are selected.  For example the gene class contains a large number of genes (gene objects) from all the organisms represented in FlyMine.  However you may only be interested in data related to one specific gene.  You would therefore constrain the gene name field of the gene class to that of the required gene.  If you wish to know about the transcripts of that gene you would combine information from the gene class and the transcripts class.  By constraining the name field of the gene class to a particular gene, you will only retrieve information from the transcripts class that relates to that gene  (ie you do not need to apply the constraint to the transcripts class as well).  This is because that particular gene object has a relationship to particular objects (instances) of the transcript class  (ie those transcripts that are produced from that particular gene).</item>
      </section>



   
	  <entry>
	      <inlinegraphic fileref="constrainDiag1.gif" format="GIF"/>
	  </entry>
  






    <section>
      <heading>The FlyMine model Browser</heading>
          <item>The FlyMine model browser allows you to select the classes that contain the objects you require. Depending on the starting class you will be able to navigate to other classes as defined by the relationships between the classes.  In other words, to combine classes containing the objects you require, you find a path though the classes that link together the information you require. Within the model browser classes that can be accessed from a parent class (ie are linked to the parent class through a relationship) are shown as fields within that class (actually a reference field, as the field is a reference to that particular class).   For example, there is a relationship between the gene class and the Transcript class.  The Transcript class therefore appears as a field within the gene class. </item>
           <item>For each class and field within the model browser there is a 'show' and a 'Constrain' (->) option. To select the subset of objects you want from a particular class you apply a constraint to appropriate field.  For example if you want objects from the Gene class which have a particlar name, you constrain the gene name field.  If you want objects from the Gene class which have a certain sequence length or range of sequence length, you constrain the seqLen field. If you are constraining a class field you will be given the option to constrain that class to any of the subtypes of that class.  E.g. The transcript class can be constrained to a number of subtypes of Transcript (e.g. primary transcript, processed transcript, tRNA etc.).  </item>
     </section>


   
	  <entry>
	      <inlinegraphic fileref="classes.gif" format="GIF"/>
	  </entry>
  


{'fraction_non_alphanumeric': 0.04548202888814243, 'fraction_numerical': 0.0006718172657037286, 'mean_word_length': 3.880655737704918, 'pattern_counts': {'":': 0, '<': 105, '<?xml version=': 2, '>': 106, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3922461', 'n_tokens_mistral': 3491, 'n_tokens_neox': 3284, 'n_words': 2240}