Constructor
new genes()
Parameters:
Name | Type | Attributes | Default | Description |
---|---|---|---|---|
layout.stroke |
string | Array.<module:LocusZoom_DataLayers~ScalableParameter> |
<optional> |
'rgb(54, 54, 150)' | The stroke color for each intron and exon |
layout.color |
string | Array.<module:LocusZoom_DataLayers~ScalableParameter> |
<optional> |
'#363696' | The fill color for each intron and exon |
layout.label_font_size |
number |
<optional> |
||
layout.label_exon_spacing |
number |
<optional> |
The number of px padding between exons and the gene label |
|
layout.exon_height |
number |
<optional> |
10 | The height of each exon (vertical line) when drawing the gene |
layout.bounding_box_padding |
number |
<optional> |
3 | Padding around edges of the bounding box, as shown when highlighting a selected gene |
layout.track_vertical_spacing |
number |
<optional> |
5 | Vertical spacing between each row of genes |
layout.tooltip_positioning |
'horizontal' | 'vertical' | 'top' | 'bottom' | 'left' | 'right' |
<optional> |
'top' | Where to draw the tooltip relative to the datum. |
- Source:
- See:
-
- module:LocusZoom_DataLayers~BaseDataLayer for additional layout options
Members
(static, constant) default_layout :Object
Type:
- Object
- Source:
gene_track_index :Object.<Number, Array>
Store information about genes in dataset, in a hash indexed by track number: {track_number: [gene_indices]}
Type:
- Object.<Number, Array>
- Source:
(protected) tracks :number
An internal counter for the number of tracks in the data layer. Used as an internal counter for looping over positions / assignments
Type:
- number
- Source:
transcript_idx :number
A gene may have arbitrarily many transcripts, but this data layer isn't set up to render them yet. Stash a transcript_idx to point to the first transcript and use that for all transcript refs.
Type:
- number
- Source:
Methods
assignTracks() → {Genes}
Ensure that genes in overlapping chromosome regions are positioned so that parts of different genes do not overlap in the view. A track is a row used to vertically separate overlapping genes.
- Source:
Returns:
- Type
- Genes
getElementStatusNodeId() → {String}
Generate a statusnode ID for a given element
- Source:
Returns:
- Type
- String
getTrackHeight() → {number}
Helper function to sum layout values to derive total height for a single gene track
- Source:
Returns:
- Type
- number
render()
Main render function
- Source: