|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objecthalflife.HalfLife
public abstract class HalfLife
Calculation of Half Lives and median-based Correction Factors
Constructor Summary | |
---|---|
HalfLife()
Constructs a HalfLife object with default Alpha |
Method Summary | |
---|---|
abstract CorrectionFactors |
calculateCorrectionFactors(double medianHWZ,
double t)
Calculation of correction factors based on a median |
abstract void |
calculateHalfLives(int t)
Calculation of Half lives |
void |
filterValues()
filters out half life values that are below 0 or NaN |
Alpha |
getAlpha()
Returns the alpha object defining the calculation method of alpha |
double |
getC_l()
Returns the correction factor c_l |
double |
getC_u()
Returns the correction factor c_u |
Data |
getData()
Returns the data object holding the original data |
double[] |
getHwz()
Returns the half life values |
Mapping<java.lang.String,java.lang.Integer> |
getNewMapping()
Returns the mapping corresponding to ratios/half lives |
double[] |
getRatio()
Returns the ratio values |
int |
getReplikat()
Returns the number of the used replicate |
abstract void |
initialize(Data data)
initializes the HalfLife object & extracts the needed values of the Data object |
abstract void |
initialize(Data data,
int replicate)
initializes the HalfLife object for a specific replicate of the data |
static double |
median(double[] inp)
Calculation of the median of a single dimensional array |
double[] |
ratioOfReplicate(double[][] rna,
double[][] total)
Calculates the ratio of a specific replicate |
void |
setAlpha(Alpha alpha)
Sets the Alpha object defining the method for calculation of alpha(t) |
abstract void |
setCorrectionFactor(CorrectionFactors corr)
Sets the set of correction factors |
void |
setCorrectionFactors(double c_u,
double c_l)
Sets the correction factors c_u and c_l |
void |
setHwz(double[] hwz)
Sets the half life values |
void |
setNewMap(Mapping<java.lang.String,java.lang.Integer> newMap)
Sets the mapping corresponding to the ratio values |
void |
writeToFileHalfLives(java.lang.String output)
Writes the half life values contained in the object together with corresponding spotIds into a file |
void |
writeToFileRatios(java.lang.String output)
Writes Ratio array into a file with two columns: column 1: spotid, column 2: corresponding ratio |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public HalfLife()
Method Detail |
---|
public abstract void initialize(Data data)
data
- The data object for which the HalfLife calculation shall be donepublic abstract void initialize(Data data, int replicate)
data
- The data object for which the HalfLife calculation shall be donereplicate
- The replicate that shall be usedpublic abstract void calculateHalfLives(int t)
t
- Timepublic abstract CorrectionFactors calculateCorrectionFactors(double medianHWZ, double t)
medianHWZ
- median mRNA Half lifet
- Time
public static double median(double[] inp)
inp
- The array for which the median shall be calculated
public void filterValues()
public double[] ratioOfReplicate(double[][] rna, double[][] total)
rna
- Set of RNA values serving as numeratortotal
- Set of RNA values serving as denominator
public void writeToFileHalfLives(java.lang.String output)
output
- Name of output filepublic void writeToFileRatios(java.lang.String output)
output
- public void setNewMap(Mapping<java.lang.String,java.lang.Integer> newMap)
newMap
- The mapping corresponding to the ratiospublic void setAlpha(Alpha alpha)
alpha
- The alpha objectpublic abstract void setCorrectionFactor(CorrectionFactors corr)
corr
- The correction factorspublic void setHwz(double[] hwz)
hwz
- The half life valuespublic void setCorrectionFactors(double c_u, double c_l)
c_u
- The correction factor c_uc_l
- The correction factor c_lpublic Alpha getAlpha()
public double getC_l()
public double getC_u()
public Mapping<java.lang.String,java.lang.Integer> getNewMapping()
public Data getData()
public double[] getHwz()
public double[] getRatio()
public int getReplikat()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |