Class CyDASGraphics
The class CyDASGraphics provides methods for the graphical representation of results from other CyDAS classes. All its methods are static (shared), no initialisation of an object is required.Overview
CyDASGraphics |
---- |
DefaultBackGroundColor(): Color {static} |
drawChromosomeBandsAsMap(Bands: Bands, Optional Scale: Single = 1, Optional Colored: Boolean = True, Optional BackGroundColor: String = ""): ImageMapData {static} |
drawChromosomeBandsAsMap(Bands: Bands, Scale: Single, Colored:Boolean, BackGroundColor: Color): ImageMapData |
drawDerivativeChromosomeAsMap(Chromosome: Chromosome, Resolution: eResolutionLevel, Optional Scale: Single = 1, Optional Colored: Boolean = True, Optional BackGroundColor: String = ""): ImageMapData {static} |
drawDerivativeChromosomeAsMap(Chromosome: Chromosome, Resolution: eResolutionLevel, Scale: Single, Colored: Boolean, BackGroundColor: Color): ImageMapData {static} |
drawGainsAndLossesAsMap(GainsAndLosses: GainsLossesStructs, Chromosome: String, Optional Scale: Single = 1, Optional CutOffLevel: Integer = 0, Optional BackGroundColor: String = ""): ImageMapData {static} |
drawGainsAndLossesAsMap(GainsAndLosses: GainsLossesStructs, Chromosome: String, Scale: Single, CutOffLevel: Integer, BackGroundColor: Color): ImageMapData {static} |
drawGainsAndLossesForAllChromosomesAsMap(GainsAndLosses: GainsLossesStructs, Optional Scale:Single = 1, Optional CutOffLevel: Integer = 0, Optional DrawSequence: String = "", Optional BackGroundColor: String = ""): ImageMapData {static} |
drawGainsAndLossesForAllChromosomesAsMap(GainsAndLosses: GainsLossesStructs, Scale:Single, CutOffLevel: Integer, DrawSequence: String, BackGroundColor: Color): ImageMapData {static} |
drawKaryogram(Chromosomes: Chromosomes, Resolution: ChromosomeData.eResolutionLevel, Scale: Single, DrawSequence: String, Colored: Boolean, BackGroundColor: Color): ImageMapData {static} |
drawStructsAsMap(StructuralAberrations: GainsLossesStructs, Chromosome: String, Optional Scale: Single = 1, Optional CutOffLevel: Integer = 0, Optional BackGroundColor: String = ""): ImageMapData {static} |
drawStructsAsMap(StructuralAberrations: GainsLossesStructs, Chromosome: String, Scale: Single, CutOffLevel: Integer, BackGroundColor: Color): ImageMapData {static} |
drawStructsForAllChromosomesAsMap(StructuralAberrations: GainsLossesStructs, Optional Scale: Single = 1, Optional CutOffLevel: Integer = 0, Optional DrawSequence: String = "", Optional BackGroundColor: String = ""): ImageMapData {static} |
drawStructsForAllChromosomesAsMap(StructuralAberrations: GainsLossesStructs, Scale: Single, CutOffLevel: Integer, DrawSequence: String, BackGroundColor: Color): ImageMapData {static} |
Programming Language
- Microsoft Visual Basic .Net.
Availability
- Copyrighted but free software under the GNU Public License.
- Binaries and source code can be obtained from the Download section.
Constructors
There is no constructor required because all functions are static (shared).Interfaces
This class does not provide interfaces.Enumerations
The class does not provide enumerations.Properties
Public Shared Property DefaultBackGroundColor() As Color
Gets or sets the default color for the background in the imagemaps.Property Value
- the default color for the background in the imagemaps.
Remarks
- The value is initialised to "Color.Transparent".
- The default color is used only when no value for the BackGroundColor parameter (string) is given.
Methods
Public Shared Function drawChromosomeBandsAsMap(ByRef Bands As Bands, Optional ByVal Scale As Single = 1, Optional ByVal Colored As Boolean = True, Optional ByVal BackGroundColor As String = "") As ImageMapData
Returns an imagemap showing the (chromosomal) bands of the Bands object.Return Value
Parameters
- Bands: a reference to the Bands object whose bands are to be drawn.
- Scale: the Scale to use for drawing. By default 1, which may result in very high bitmaps (ca. 1600 pixels for non-aberrant human chromosome #1).
- Colored: indicates if colors are to be used for drawing (default) or if the drawing is in black and white only.
- BackGroundColor: the name of a known color which is to be used for the background. If not given, the DefaultBackGroundColor will be used.
Remarks
- The bands object has to be adjusted to the desired banding resolution before passing it to this function.
- The name of the color is translated into a Color object using the Color.FromName function.
- The function passes through to the other drawChromosomeBandsAsMap function.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
drawChromosomeBandsAsMap(ByRef Bands As Bands, ByVal Scale As Single, ByVal Colored As Boolean, ByRef BackGroundColor As Color) As ImageMapData
Returns an imagemap showing the (chromosomal) bands of the Bands object.Return Value
Parameters
- Bands: a reference to the Bands object whose bands are to be drawn.
- Scale: the Scale to use for drawing.
- Colored: indicates if colors are to be used for drawing (default) or if the drawing is in black and white only.
- BackGroundColor: the color which is to be used for the background.
Remarks
- No parameter is optional, values must be given for every parameter.
- The bands object has to be adjusted to the desired banding resolution before passing it to this function.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
drawDerivativeChromosomeAsMap(ByRef Chromosome As Chromosome, ByVal Resolution As ChromosomeData.eResolutionLevel, Optional ByVal Scale As Single = 1, Optional ByVal Colored As Boolean = True, Optional ByVal BackGroundColor As String = "") As ImageMapData
Returns an imagemap showing the bands of a derivative chromosome.Return Value
- an imagemap showing the bands of a derivative chromosome.
Parameters
- Chromosome: a reference to an object describing the derivative Chromosome whose bands are to be drawn.
- Resolution: the banding resolution to be used for drawing. Acceptable values are defined in the ChromosomeData.eResolutionLevel enumeration.
- Scale: the Scale to use for drawing. By default 1, which may result in very high bitmaps (ca. 1600 pixels for non-aberrant human chromosome #1).
- Colored: indicates if colors are to be used for drawing (default) or if the drawing is in black and white only.
- BackGroundColor: the name of a known color which is to be used for the background. If not given, the DefaultBackGroundColor will be used.
Remarks
- The name of the color is translated into a Color object using the Color.FromName function.
- The function passes through to the other drawDerivativeChromosomeAsMap function which calls Chromosome.getContainedBands on the chromsome and then delegates to drawChromosomeBandsAsMap.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
Examples
- To get an imagemap of the Philadelphia chromosome at 400 bphs level, do:
Dim myAberration As Aberration
Dim myChromosome As Chromosome
Dim myImageMap as ImageMapData
myAberration = New Aberration("der(22)t(9;22)(q34;q112)")
myChromosome = myAberration.getDerivateChromosome
myBitmap = CyDASGraphics.drawDerivativeChromosomeAsMap(myChromosome, Resolution400Bands)
drawDerivativeChromosomeAsMap(ByRef Chromosome As Chromosome, ByVal Resolution As ChromosomeData.eResolutionLevel, ByVal Scale As Single, ByVal Colored As Boolean, ByRef BackGroundColor As Color) As ImageMapData
Returns an imagemap showing the bands of a derivative chromosome.Return Value
- an imagemap showing the bands of a derivative chromosome.
Parameters
- Chromosome: a reference to an object describing the derivative Chromosome whose bands are to be drawn.
- Resolution: the banding resolution to be used for drawing. Acceptable values are defined in the ChromosomeData.eResolutionLevel enumeration.
- Scale: the Scale to use for drawing.
- Colored: indicates if colors are to be used for drawing or if the drawing is in black and white only.
- BackGroundColor: the color which is to be used for the background.
Remarks
- No parameter is optional, values must be given for every parameter.
- The function which calls Chromosome.getContainedBands on the chromsome and then delegates to drawChromosomeBandsAsMap.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
Public Shared Function drawGainsAndLossesAsMap(ByRef GainsAndLosses As GainsLossesStructs, ByVal Chromosome As String, Optional ByVal Scale As Single = 1, Optional ByVal CutOffLevel As Integer = 0, Optional ByVal BackGroundColor As String = "") As ImageMapData
Returns an imagemap showing the gains and losses of chromosomal material next to the idiogram of the given chromosome.Return Value
- an imagemap showing the gains and losses of chromosomal material.
Parameters
- GainsAndLosses: a GainsLossesStructs object for the gains and losses to be shown.
- Chromosome: the number of the (normal) Chromosome for which gains and losses are to be shown.
- Scale: the Scale to use for drawing. By default 1, which may result in very high bitmaps (ca. 1600 pixels for non-aberrant human chromosome #1).
- CutOffLevel: the maximum value for a gain or loss to be shown. If the value of a gain or loss is greater, only this CutOffLevel value will be drawn. If no cut off is desired, CutOffLevel is set to 0.
- BackGroundColor: the name of a known color which is to be used for the background. If not given, the DefaultBackGroundColor will be used.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosomes are drawn in black and white.
- Losses are drawn to the left of the chromosome in red color, gains to the right in green color.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas for bands and losses are linked with information on the position (band number) and the amount of gains or losses at that position.
- The function passes through to the other drawGainsAndLossesAsMap function.
Public Shared Function drawGainsAndLossesAsMap(ByRef GainsAndLosses As GainsLossesStructs, ByVal Chromosome As String, ByVal Scale As Single, ByVal CutOffLevel As Integer, ByRef BackGroundColor As Color) As ImageMapData
Returns an imagemap showing the gains and losses of chromosomal material next to the idiogram of the given chromosome.Return Value
- an imagemap showing the gains and losses of chromosomal material.
Parameters
- GainsAndLosses: a GainsLossesStructs object for the gains and losses to be shown.
- Chromosome: the number of the (normal) Chromosome for which gains and losses are to be shown.
- Scale: the Scale to use for drawing.
- CutOffLevel: the maximum value for a gain or loss to be shown. If no cut off is desired, CutOffLevel is set to 0.
- BackGroundColor: the color which is to be used for the background.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosomes are drawn in black and white.
- Losses are drawn to the left of the chromosome in red color, gains to the right in green color.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas for bands and losses are linked with information on the position (band number) and the amount of gains or losses at that position.
Public Shared Function drawGainsAndLossesForAllChromosomes(ByRef GainsAndLosses As GainsLossesStructs, Optional ByVal Scale As Single = 1, Optional ByVal CutOffLevel As Integer = 0, Optional ByVal DrawSequence As String = "", Optional ByVal BackGroundColor As String = "") As ImageMapData
Returns an imagemap showing the gains and losses of material of all chromosomes defined in DrawSequence next to their ideograms.Return Value
- an imagemap showing the gains and losses of material of the chromosomes.
Parameters
- GainsAndLosses: a GainsLossesStructs object for the gains and losses to be shown.
- Scale: the Scale to use for drawing. By default 1, which may result in very large bitmaps (ca. 3300 x 2600 pixels for default drawing order).
- CutOffLevel: the maximum value for a gain or loss to be shown. If the value of a gain or loss is greater, only this CutOffLevel value will be drawn. If no cut off is desired, CutOffLevel is set to 0.
- DrawSequence: a comma separated list of the sequence in which the chromosomes are to be drawn. Line breaks are indicated by "BR". A default is taken from the Resource file.
- BackGroundColor: the name of a known color which is to be used for the background. If not given, the DefaultBackGroundColor will be used.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosome ideograms are drawn in black and white.
- Losses are drawn to the left of the chromosome in red color, gains to the right in green color.
- If only a few chromosomes are to be drawn, it is sufficient to name them in the DrawingSequence.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas for bands and losses are linked with information on the position (band number) and the amount of gains or losses at that position.
- The function passes through to the other drawGainsAndLossesForAllChromosomesAsMap function.
Public Shared Function drawGainsAndLossesForAllChromosomesAsMap(ByRef GainsAndLosses As GainsLossesStructs, ByVal Scale As Single, ByVal CutOffLevel As Integer, ByVal DrawSequence As String, ByRef BackGroundColor As Color) As ImageMapData
Returns an imagemap showing the gains and losses of material of all chromosomes defined in DrawSequence next to their ideograms.Return Value
- an imagemap showing the gains and losses of material of the chromosomes.
Parameters
- GainsAndLosses: a GainsLossesStructs object for the gains and losses to be shown.
- Scale: the Scale to use for drawing.
- CutOffLevel: the maximum value for a gain or loss to be shown. If the value of a gain or loss is greater, only this CutOffLevel value will be drawn. If no cut off is desired, CutOffLevel is set to 0.
- DrawSequence: a comma separated list of the sequence in which the chromosomes are to be drawn. Line breaks are indicated by "BR". A default is taken from the Resource file.
- BackGroundColor: the color which is to be used for the background.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosome ideograms are drawn in black and white.
- Losses are drawn to the left of the chromosome in red color, gains to the right in green color.
- If only a few chromosomes are to be drawn, it is sufficient to name them in the DrawingSequence.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas for bands and losses are linked with information on the position (band number) and the amount of gains or losses at that position.
Public Shared Function drawKaryogram(ByRef Chromosomes As Chromosomes, ByVal Resolution As ChromosomeData.eResolutionLevel, ByVal Scale As Single, ByVal DrawSequence As String, ByVal Colored As Boolean, ByVal BackGroundColor As Color) As ImageMapData
Returns an imagemap showing ideograms for all chromosomes of the Chromosomes collection in the series defined in DrawSequence.Return Value
- an imagemap showing ideograms for all chromosomes.
Parameters
- Chromosomes: a collection (reference to a Chromosomes object) of all the normal and derivative chromosomes to be shown.
- Resolution: the banding resolution to be used for drawing. Values are defined in the ChromosomeData.eResolutionLevel enumeration.
- Scale: the Scale to use for drawing.
- DrawSequence: a comma separated list of the sequence in which the chromosomes are to be drawn. Line breaks are indicated by "BR". A default is taken from the Resource file.
- Colored: indicates if chromosome ideograms are shown in color or in black and white only.
- BackGroundColor: the color which is to be used for the background.
Remarks
- If only a few chromosomes are to be drawn, it is sufficient to name them in the DrawingSequence.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The centromeres of the chromosomes are on one line.
Public Shared Function drawStructsAsMap(ByRef StructuralAberrations As GainsLossesStructs, ByVal Chromosome As String, Optional ByVal Scale As Single = 1, Optional ByVal CutOffLevel As Integer = 0, Optional ByVal BackGroundColor As String = "") As ImageMapData
Returns an imagemap showing the structural aberrations along a chromosome.Return Value
- an imagemap showing the structural aberrations along a chromosome.
Parameters
- StructuralAberrations: a GainsLossesStructs object for the structural aberrations to be shown.
- Chromosome: the number of the (normal) Chromosome for which structural aberrations are to be shown.
- Scale: the Scale to use for drawing. By default 1, which may result in very high bitmaps (ca. 1600 pixels for non-aberrant human chromosome #1).
- CutOffLevel: the maximum value for a structural aberration to be shown. If the frequency of a structural aberration is greater, only this CutOffLevel value will be drawn. If no cut off is desired, CutOffLevel is set to 0.
- BackGroundColor: the name of a known color which is to be used for the background. If not given, the DefaultBackGroundColor will be used.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosome ideograms are drawn in black and white.
- Structural aberrations are drawn to the right of the chromosome in blue color.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas representing the structural aberrations are linked with information on the position (band number) and the amount of rearrangements at that position.
- The function passes through to the other drawStructsAsMap function.
Public Shared Function drawStructsAsMap(ByRef StructuralAberrations As GainsLossesStructs, ByVal Chromosome As String, ByVal Scale As Single, ByVal CutOffLevel As Integer, ByRef BackGroundColor As Color) As ImageMapData
Returns an imagemap showing the structural aberrations along a chromosome.Return Value
- an imagemap showing the structural aberrations along a chromosome.
Parameters
- StructuralAberrations: a GainsLossesStructs object for the structural aberrations to be shown.
- Chromosome: the number of the (normal) Chromosome for which structural aberrations are to be shown.
- Scale: the Scale to use for drawing.
- CutOffLevel: the maximum value for a structural aberration to be shown. If the frequency of a structural aberration is greater, only this CutOffLevel value will be drawn. If no cut off is desired, CutOffLevel is set to 0.
- BackGroundColor: the color which is to be used for the background.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosome ideograms are drawn in black and white.
- Structural aberrations are drawn to the right of the chromosome in blue color.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas representing the structural aberrations are linked with information on the position (band number) and the amount of rearrangements at that position.
Public Shared Function drawStructsForAllChromosomesAsMap(ByRef StructuralAberrations As GainsLossesStructs, Optional ByVal Scale As Single = 1, Optional ByVal CutOffLevel As Integer = 0, Optional ByVal DrawSequence As String = "", Optional ByVal BackGroundColor As String = "") As ImageMapData
Returns an imagemap showing the structural aberrations along the chromosomes.Return Value
- an imagemap showing the structural aberrations along the chromosomes.
Parameters
- StructuralAberrations: a GainsLossesStructs object for the structural aberrations to be shown.
- Scale: the Scale to use for drawing. By default 1, which may result in very large bitmaps (ca. 3300 x 1800 pixels for default drawing order).
- CutOffLevel: the maximum value for a structural aberrations to be shown. If the frequency of a structural aberration is greater, only this CutOffLevel value will be drawn. If no cut off is desired, CutOffLevel is set to 0.
- DrawSequence: a comma separated list of the sequence in which the chromosomes are to be drawn. Line breaks are indicated by "BR". A default is taken from the Resource file.
- BackGroundColor: the name of a known color which is to be used for the background. If not given, the DefaultBackGroundColor will be used.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosomes are drawn in black and white.
- Structural aberrations are drawn to the right of the chromosome in blue color.
- If only a few chromosomes are to be drawn, it is sufficient to name them in the DrawSequence.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas representing the structural aberrations are linked with information on the position (band number) and the amount of rearrangements at that position.
- The function passes through to the other drawStructsForAllChromosomesAsMap function.
Public Shared Function drawStructsForAllChromosomesAsMap(ByRef StructuralAberrations As GainsLossesStructs, ByVal Scale As Single, ByVal CutOffLevel As Integer, ByVal DrawSequence As String, ByRef BackGroundColor As Color) As ImageMapData
Returns an imagemap showing the structural aberrations along the chromosomes.Return Value
- an imagemap showing the structural aberrations along the chromosomes.
Parameters
- StructuralAberrations: a GainsLossesStructs object for the structural aberrations to be shown.
- Scale: the Scale to use for drawing.
- CutOffLevel: the maximum value for a structural aberrations to be shown. If the frequency of a structural aberration is greater, only this CutOffLevel value will be drawn. If no cut off is desired, CutOffLevel is set to 0.
- DrawSequence: a comma separated list of the sequence in which the chromosomes are to be drawn. Line breaks are indicated by "BR". A default is taken from the Resource file.
- BackGroundColor: the color which is to be used for the background.
Remarks
- The resolution is taken from the GainsLossesStructs object.
- Chromosomes are drawn in black and white.
- Structural aberrations are drawn to the right of the chromosome in blue color.
- If only a few chromosomes are to be drawn, it is sufficient to name them in the DrawSequence.
- All chromosomal bands are linked to the Map Viewer defined in ChromosomeData.MapViewer.
- The areas representing the structural aberrations are linked with information on the position (band number) and the amount of rearrangements at that position.