Navigation:  Graphic notation editor > Formal definition of graphic notation >

SBGN example - macromolecule

PDF version of the documentation Print this Topic Previous pageReturn to chapter overviewNext page

Biological processes involve many different macromolecules that are built upon the covalent linking of pseudo-identical units. Examples are proteins, nucleic acids (RNA, DNA) or polysaccharides (glycogen, cellulose, starch . . . ). In order to limit the explosion of symbols to be absorbed by the community, SBGN Level 1 defines only one glyph that represents a macromolecule. The same glyph is to be used for a protein, a nucleic acid, a complex sugar etc. Further Levels of SBGN might subclass this concept and propose different glyphs for different types of macromolecules.

Specification

container:

A macromolecule is represented by a round-corner rectangular container.

label:

The identification of the macromolecule is carried by an unbordered box containing a string of characters. The characters can be distributed on several lines to improve readability, although this is not mandatory. The label box has to be attached to the center of the container box. Note that the label can spill-over from the container box.

auxiliary items:

A macromolecule can carry a certain number of state variables, that will add information about its precise state. The state of a macromolecule is therefore defined as the vector of all the state variables. A state variable is represented by an ellipsoid. The large axis of the ellipsoid is located on the border of the macromolecule container box. The label of the state variable (type of characteristic, residue type, residue number) can be optionally written, either within the macromolecule container box, beside the border of the state variable box, or within the modificator box itself.

A macromolecule can also carry one or several units of information. Those units of information can characterise a domain, such as a binding site, or an exon. Particular units of information carry the material type of the macromolecules and the conceptual types of the macromolecules. The center of the bounding box of a unit of information is located on the midline of the border of the compartment.

 

macromolecule-sbgn

macromolecule-biouml

SBGN specification

BioUML realization

Formal definition

 

<node icon="icon4" isCompartment="true" type="macromolecule">

<propertyRef name="multimer" value="0"/>

</node>

 

<nodeView type="macromolecule"><![CDATA[function f(container, node, options, g)

{

   var d, pen, brush;

   d = node.getValue("shapeSize", null);

   if(d.width == 0 && d.height == 0)

   {

       d.width = 70;

       d.height = 40;

   }

   brush = new Brush(new Color(0.9, 1.0, 0.9));

   pen = options.getDefaultPen();

   var multimer = node.getValue("multimer", 0);

   if(multimer>1)

   {

        var rect = new RoundRectangle2D.Float(5, 5, d.width, d.height, 20, 20);

        var box = new BoxView(pen, brush, rect);

        container.add(box);

   }

   var rect = new RoundRectangle2D.Float(0, 0, d.width, d.height, 20, 20);

   var box = new BoxView(pen, brush, rect);

   container.add(box);

   var title = new TextView(node.getValue('title', ''), options.getNodeTitleFont(), g);

   container.add(title, CompositeView.X_CC | CompositeView.Y_CC);

   if(multimer>1)

   {

        var mbox = new BoxView(pen, brush, 10, -10, 20, 20);

        container.add(mbox);

        var mcount = new TextView(node.getValue('multimer', '...'), options.getNodeTitleFont(), g);

        var mPosition = new Point(15, 2);

        container.add(mcount, CompositeView.X_LL | CompositeView.Y_TT, mPosition);

   }

   return false;

}]]></nodeView>