org.agmodel.bioinfo.segregation
Class MapFunction
java.lang.Object
org.agmodel.bioinfo.segregation.MapFunction
- public class MapFunction
- extends java.lang.Object
Method Summary |
double |
getDistance(double r)
|
int |
getFunction()
|
static java.lang.String |
getFunctionName(int function)
|
double |
getHaldaneDistance(double r)
Calculate map distance from recombination rate on the basis of Holdane's function |
double |
getHaldaneRate(double x)
Calculate recombination rate from map distance on the basis of Holdane's function |
double |
getKosambiDistance(double r)
Calculate map distance from recombination rate on the basis of Kosambi's function |
double |
getKosambiRate(double x)
Calculate recombination rate from map distance on the basis of Kosambi's function |
double |
getRate(double x)
|
void |
setFunction(int i)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MF_HALDANE
public static final int MF_HALDANE
- See Also:
- Constant Field Values
MF_KOSAMBI
public static final int MF_KOSAMBI
- See Also:
- Constant Field Values
MAX_DIST
public static final double MAX_DIST
- See Also:
- Constant Field Values
MF_HALDANE_NAME
public static final java.lang.String MF_HALDANE_NAME
- See Also:
- Constant Field Values
MF_KOSAMBI_NAME
public static final java.lang.String MF_KOSAMBI_NAME
- See Also:
- Constant Field Values
MapFunction
public MapFunction()
MapFunction
public MapFunction(int function)
getRate
public double getRate(double x)
getFunctionName
public static java.lang.String getFunctionName(int function)
getDistance
public double getDistance(double r)
getHaldaneRate
public double getHaldaneRate(double x)
- Calculate recombination rate from map distance on the basis of Holdane's function
- Parameters:
x
- Map distance. The unit is Morgan.
- Returns:
- Recombination rate.
getHaldaneDistance
public double getHaldaneDistance(double r)
- Calculate map distance from recombination rate on the basis of Holdane's function
- Parameters:
r
- Recombination rate.
- Returns:
- Map distance. The unit is Morgan.
getKosambiRate
public double getKosambiRate(double x)
- Calculate recombination rate from map distance on the basis of Kosambi's function
- Parameters:
x
- Map distance. The unit is Morgan.
- Returns:
- Recombination rate.
getKosambiDistance
public double getKosambiDistance(double r)
- Calculate map distance from recombination rate on the basis of Kosambi's function
- Parameters:
r
- Recombinatino rate.
- Returns:
- Map distance. The unit is Morgan.
getFunction
public int getFunction()
- Returns:
setFunction
public void setFunction(int i)
- Parameters:
i
-