org.geworkbench.bison.datastructure.bioobjects.microarray
Class CSGenotypicMarkerValue

java.lang.Object
  extended by org.geworkbench.bison.datastructure.bioobjects.microarray.CSMarkerValue
      extended by org.geworkbench.bison.datastructure.bioobjects.microarray.CSGenotypicMarkerValue
All Implemented Interfaces:
java.io.Serializable, java.lang.Comparable, DSGenotypicMarkerValue, DSMarkerValue, DSMutableMarkerValue

public class CSGenotypicMarkerValue
extends CSMarkerValue
implements java.io.Serializable, DSGenotypicMarkerValue

Title: Plug And Play

Description: Dynamic Proxy Implementation of enGenious

Copyright: Copyright (c) 2002

Company: First Genetic Trust Inc.

Version:
1.0
Author:
Manjunath Kustagi
See Also:
Serialized Form

Field Summary
protected static java.text.DecimalFormat formatter
          Formats values to be displayed
 boolean isGT
          Bit to specify if this marker contains two alleles
 
Fields inherited from class org.geworkbench.bison.datastructure.bioobjects.microarray.CSMarkerValue
confidence, m_threshold, MISSING, p_threshold, value
 
Constructor Summary
CSGenotypicMarkerValue(CSGenotypicMarkerValue mg)
          Constructor
CSGenotypicMarkerValue(int allele_1)
          Constructor to create this marker from one allele
CSGenotypicMarkerValue(int a1, int a2)
          Constructor to create this marker from two alleles
 
Method Summary
 int compareTo(java.lang.Object o)
           
 DSMarkerValue deepCopy()
          Gets a copy of this marker
 boolean equals(DSMarkerValue m)
           
 java.awt.Color getAbsColor(DSRangeMarker stats, float intensity)
           
 short getAllele(int id)
          Gets either of the two alleles
 java.awt.Color getColor(DSRangeMarker stats, float intensity)
           
 int getDimensionality()
          This method returns the dimensionality of the marker.
 java.lang.Class getMarkerStatsClass()
           
 double getValue()
          Return the signal measurement for this spot.
 void parse(java.lang.String signal, int gtBase)
           
 void parse(java.lang.String signal, java.lang.String status, int gtBase)
           
 java.lang.String representation()
          Obtains a String representation of the genotype
 void setAllele(int allele)
          Sets the primary allele
 void setGenotype(int allele0, int allele1)
          Sets genotype
 java.lang.String toString()
          Gets a String representation of this marker
 
Methods inherited from class org.geworkbench.bison.datastructure.bioobjects.microarray.CSMarkerValue
equals, getConfidence, getStatusAsChar, isAbsent, isMarginal, isMasked, isMissing, isPresent, isValid, mask, setAbsent, setConfidence, setMarginal, setMarginalThreshold, setMissing, setPresent, setPresentThreshold, setValue, unmask
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.geworkbench.bison.datastructure.bioobjects.microarray.DSMutableMarkerValue
mask, setConfidence, setMissing, setValue, unmask
 
Methods inherited from interface org.geworkbench.bison.datastructure.bioobjects.microarray.DSMarkerValue
equals, getConfidence, isMasked, isMissing, isValid
 

Field Detail

formatter

protected static java.text.DecimalFormat formatter
Formats values to be displayed


isGT

public boolean isGT
Bit to specify if this marker contains two alleles

Constructor Detail

CSGenotypicMarkerValue

public CSGenotypicMarkerValue(CSGenotypicMarkerValue mg)
Constructor

Parameters:
mg - MarkerGenotype to be cloned

CSGenotypicMarkerValue

public CSGenotypicMarkerValue(int a1,
                              int a2)
Constructor to create this marker from two alleles

Parameters:
a1 - int allele
a2 - int allele

CSGenotypicMarkerValue

public CSGenotypicMarkerValue(int allele_1)
Constructor to create this marker from one allele

Parameters:
allele_1 - int
Method Detail

setAllele

public void setAllele(int allele)
Sets the primary allele

Specified by:
setAllele in interface DSGenotypicMarkerValue
Parameters:
allele - int

setGenotype

public void setGenotype(int allele0,
                        int allele1)
Sets genotype

Specified by:
setGenotype in interface DSGenotypicMarkerValue
Parameters:
allele0 - int
allele1 - int

getAllele

public short getAllele(int id)
Gets either of the two alleles

Specified by:
getAllele in interface DSGenotypicMarkerValue
Parameters:
id - int either of the two dimensions
Returns:
int allele as int

representation

public java.lang.String representation()
Obtains a String representation of the genotype

Returns:
String representation

toString

public java.lang.String toString()
Gets a String representation of this marker

Overrides:
toString in class java.lang.Object
Returns:
String

equals

public boolean equals(DSMarkerValue m)
Parameters:
m - IMarker
Returns:
boolean

getDimensionality

public int getDimensionality()
This method returns the dimensionality of the marker. Genotype markers are 2-dimensional while Allele/Haplotype markers are 1-dimensional

Specified by:
getDimensionality in interface DSMarkerValue
Returns:
the dimensionality of the marker.

deepCopy

public DSMarkerValue deepCopy()
Gets a copy of this marker

Specified by:
deepCopy in interface DSMarkerValue
Returns:
MarkerValue

parse

public void parse(java.lang.String signal,
                  int gtBase)

parse

public void parse(java.lang.String signal,
                  java.lang.String status,
                  int gtBase)

getMarkerStatsClass

public java.lang.Class getMarkerStatsClass()

getColor

public java.awt.Color getColor(DSRangeMarker stats,
                               float intensity)

getAbsColor

public java.awt.Color getAbsColor(DSRangeMarker stats,
                                  float intensity)

getValue

public double getValue()
Description copied from interface: DSMarkerValue
Return the signal measurement for this spot. For 2-channel data, this is usually the ratio of the 2 channels.

Specified by:
getValue in interface DSMarkerValue
Overrides:
getValue in class CSMarkerValue
Returns:
marker value

compareTo

public int compareTo(java.lang.Object o)
Specified by:
compareTo in interface java.lang.Comparable