11 |
13 Sep 07 |
nicklas |
1 |
////////////////////////////////////////////////////////////////// |
11 |
13 Sep 07 |
nicklas |
2 |
// |
11 |
13 Sep 07 |
nicklas |
// Copyright (C) 2005 Affymetrix, Inc. |
11 |
13 Sep 07 |
nicklas |
4 |
// |
11 |
13 Sep 07 |
nicklas |
// This library is free software; you can redistribute it and/or modify |
11 |
13 Sep 07 |
nicklas |
// it under the terms of the GNU Lesser General Public License as published |
11 |
13 Sep 07 |
nicklas |
// by the Free Software Foundation; either version 2.1 of the License, |
11 |
13 Sep 07 |
nicklas |
// or (at your option) any later version. |
11 |
13 Sep 07 |
nicklas |
9 |
// |
11 |
13 Sep 07 |
nicklas |
// This library is distributed in the hope that it will be useful, but |
11 |
13 Sep 07 |
nicklas |
// WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY |
11 |
13 Sep 07 |
nicklas |
// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License |
11 |
13 Sep 07 |
nicklas |
// for more details. |
11 |
13 Sep 07 |
nicklas |
14 |
// |
11 |
13 Sep 07 |
nicklas |
// You should have received a copy of the GNU Lesser General Public License |
11 |
13 Sep 07 |
nicklas |
// along with this library; if not, write to the Free Software Foundation, Inc., |
11 |
13 Sep 07 |
nicklas |
// 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
11 |
13 Sep 07 |
nicklas |
18 |
// |
11 |
13 Sep 07 |
nicklas |
19 |
///////////////////////////////////////////////////////////////// |
11 |
13 Sep 07 |
nicklas |
20 |
|
11 |
13 Sep 07 |
nicklas |
21 |
package affymetrix.gcos.chp; |
11 |
13 Sep 07 |
nicklas |
22 |
|
11 |
13 Sep 07 |
nicklas |
/** Defines the results for an expression probe set. */ |
11 |
13 Sep 07 |
nicklas |
24 |
public class ExpressionProbeSetResults { |
11 |
13 Sep 07 |
nicklas |
25 |
|
11 |
13 Sep 07 |
nicklas |
/** Present call for expression analysis */ |
11 |
13 Sep 07 |
nicklas |
27 |
public static final byte ABS_PRESENT_CALL = 0; |
11 |
13 Sep 07 |
nicklas |
28 |
|
11 |
13 Sep 07 |
nicklas |
/** Marginal call for expression analysis */ |
11 |
13 Sep 07 |
nicklas |
30 |
public static final byte ABS_MARGINAL_CALL = 1; |
11 |
13 Sep 07 |
nicklas |
31 |
|
11 |
13 Sep 07 |
nicklas |
/** Absent call for expression analysis */ |
11 |
13 Sep 07 |
nicklas |
33 |
public static final byte ABS_ABSENT_CALL = 2; |
11 |
13 Sep 07 |
nicklas |
34 |
|
11 |
13 Sep 07 |
nicklas |
/** No call call for expression analysis */ |
11 |
13 Sep 07 |
nicklas |
36 |
public static final byte ABS_NO_CALL = 3; |
11 |
13 Sep 07 |
nicklas |
37 |
|
11 |
13 Sep 07 |
nicklas |
/** Increase call for expression comparison analysis */ |
11 |
13 Sep 07 |
nicklas |
39 |
public static final byte COMP_INCREASE_CALL = 1; |
11 |
13 Sep 07 |
nicklas |
40 |
|
11 |
13 Sep 07 |
nicklas |
/** Decrease call for expression comparison analysis */ |
11 |
13 Sep 07 |
nicklas |
42 |
public static final byte COMP_DECREASE_CALL = 2; |
11 |
13 Sep 07 |
nicklas |
43 |
|
11 |
13 Sep 07 |
nicklas |
/** Moderate increase call for expression comparison analysis */ |
11 |
13 Sep 07 |
nicklas |
45 |
public static final byte COMP_MOD_INCREASE_CALL = 3; |
11 |
13 Sep 07 |
nicklas |
46 |
|
11 |
13 Sep 07 |
nicklas |
/** Moderate decrease call for expression comparison analysis */ |
11 |
13 Sep 07 |
nicklas |
48 |
public static final byte COMP_MOD_DECREASE_CALL = 4; |
11 |
13 Sep 07 |
nicklas |
49 |
|
11 |
13 Sep 07 |
nicklas |
/** No change call for expression comparison analysis */ |
11 |
13 Sep 07 |
nicklas |
51 |
public static final byte COMP_NO_CHANGE_CALL = 5; |
11 |
13 Sep 07 |
nicklas |
52 |
|
11 |
13 Sep 07 |
nicklas |
/** No call call for expression comparison analysis */ |
11 |
13 Sep 07 |
nicklas |
54 |
public static final byte COMP_NO_CALL = 6; |
11 |
13 Sep 07 |
nicklas |
55 |
|
11 |
13 Sep 07 |
nicklas |
/** The detection p-value */ |
11 |
13 Sep 07 |
nicklas |
57 |
private float detectionPValue; |
11 |
13 Sep 07 |
nicklas |
58 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the detection p-value |
11 |
13 Sep 07 |
nicklas |
* @return The detection p-value. |
11 |
13 Sep 07 |
nicklas |
61 |
*/ |
11 |
13 Sep 07 |
nicklas |
62 |
public float getDetectionPValue() { return detectionPValue; } |
11 |
13 Sep 07 |
nicklas |
63 |
|
11 |
13 Sep 07 |
nicklas |
/** Sets the detection p-value |
11 |
13 Sep 07 |
nicklas |
* @param p The detection p-value. |
11 |
13 Sep 07 |
nicklas |
66 |
*/ |
11 |
13 Sep 07 |
nicklas |
67 |
public void setDetectionPValue(float p) { detectionPValue=p; } |
11 |
13 Sep 07 |
nicklas |
68 |
|
11 |
13 Sep 07 |
nicklas |
/** The signal value */ |
11 |
13 Sep 07 |
nicklas |
70 |
private float signal; |
11 |
13 Sep 07 |
nicklas |
71 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the signal |
11 |
13 Sep 07 |
nicklas |
* @return The signal. |
11 |
13 Sep 07 |
nicklas |
74 |
*/ |
11 |
13 Sep 07 |
nicklas |
75 |
public float getSignal() { return signal; } |
11 |
13 Sep 07 |
nicklas |
76 |
|
11 |
13 Sep 07 |
nicklas |
/** Sets the signal |
11 |
13 Sep 07 |
nicklas |
* @param s The signal. |
11 |
13 Sep 07 |
nicklas |
79 |
*/ |
11 |
13 Sep 07 |
nicklas |
80 |
public void setSignal(float s) { signal=s; } |
11 |
13 Sep 07 |
nicklas |
81 |
|
11 |
13 Sep 07 |
nicklas |
/** The number of probe pairs in the set */ |
11 |
13 Sep 07 |
nicklas |
83 |
private short numPairs; |
11 |
13 Sep 07 |
nicklas |
84 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the number of probe pairs in the set. |
11 |
13 Sep 07 |
nicklas |
* @return The number of pairs. |
11 |
13 Sep 07 |
nicklas |
87 |
*/ |
11 |
13 Sep 07 |
nicklas |
88 |
public short getNumPairs() { return numPairs; } |
11 |
13 Sep 07 |
nicklas |
89 |
|
11 |
13 Sep 07 |
nicklas |
/** Sets the number of probe pairs in the set. |
11 |
13 Sep 07 |
nicklas |
* @param n The number of pairs. |
11 |
13 Sep 07 |
nicklas |
92 |
*/ |
11 |
13 Sep 07 |
nicklas |
93 |
public void setNumPairs(short n) { numPairs=n; } |
11 |
13 Sep 07 |
nicklas |
94 |
|
11 |
13 Sep 07 |
nicklas |
/** The number of probe pairs used to calculate the signal value */ |
11 |
13 Sep 07 |
nicklas |
96 |
private short numUsedPairs; |
11 |
13 Sep 07 |
nicklas |
97 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the number of probe pairs used to calculate the signal. |
11 |
13 Sep 07 |
nicklas |
* @return The number of pairs used to calculate the signal. |
11 |
13 Sep 07 |
nicklas |
100 |
*/ |
11 |
13 Sep 07 |
nicklas |
101 |
public short getNumUsedPairs() { return numUsedPairs; } |
11 |
13 Sep 07 |
nicklas |
102 |
|
11 |
13 Sep 07 |
nicklas |
/** Sets the number of probe pairs used to calculate the signal. |
11 |
13 Sep 07 |
nicklas |
* @param n The number of pairs used to calculate the signal. |
11 |
13 Sep 07 |
nicklas |
105 |
*/ |
11 |
13 Sep 07 |
nicklas |
106 |
public void setNumUsedPairs(short n) { numUsedPairs=n; } |
11 |
13 Sep 07 |
nicklas |
107 |
|
11 |
13 Sep 07 |
nicklas |
/** The detection call */ |
11 |
13 Sep 07 |
nicklas |
109 |
private byte detection; |
11 |
13 Sep 07 |
nicklas |
110 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the detection. |
11 |
13 Sep 07 |
nicklas |
* @return The detection. |
11 |
13 Sep 07 |
nicklas |
113 |
*/ |
11 |
13 Sep 07 |
nicklas |
114 |
public byte getDetection() { return detection; } |
11 |
13 Sep 07 |
nicklas |
115 |
|
11 |
13 Sep 07 |
nicklas |
/** Sets the detection. |
11 |
13 Sep 07 |
nicklas |
* @param d The detection. |
11 |
13 Sep 07 |
nicklas |
118 |
*/ |
11 |
13 Sep 07 |
nicklas |
119 |
public void setDetection(byte d) { detection=d; } |
11 |
13 Sep 07 |
nicklas |
120 |
|
11 |
13 Sep 07 |
nicklas |
/** Flag indicating that comparison results exist */ |
11 |
13 Sep 07 |
nicklas |
122 |
private boolean hasCompResults; |
11 |
13 Sep 07 |
nicklas |
123 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets a flag that indicates if comparison data exists. |
11 |
13 Sep 07 |
nicklas |
* @return The flag that indicates if comparison data exists. |
11 |
13 Sep 07 |
nicklas |
126 |
*/ |
11 |
13 Sep 07 |
nicklas |
127 |
public boolean getHasCompResults() { return hasCompResults; } |
11 |
13 Sep 07 |
nicklas |
128 |
|
11 |
13 Sep 07 |
nicklas |
/** Sets a flag that indicates if comparison data exists. |
11 |
13 Sep 07 |
nicklas |
* @param b The flag that indicates if comparison data exists. |
11 |
13 Sep 07 |
nicklas |
131 |
*/ |
11 |
13 Sep 07 |
nicklas |
132 |
public void setHasCompResults(boolean b) { hasCompResults=b; } |
11 |
13 Sep 07 |
nicklas |
133 |
|
11 |
13 Sep 07 |
nicklas |
/** The change p-value */ |
11 |
13 Sep 07 |
nicklas |
135 |
private float changePValue; |
11 |
13 Sep 07 |
nicklas |
136 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the change p-value |
11 |
13 Sep 07 |
nicklas |
* @return The change p-value |
11 |
13 Sep 07 |
nicklas |
139 |
*/ |
11 |
13 Sep 07 |
nicklas |
140 |
public float getChangePValue() { return changePValue; } |
11 |
13 Sep 07 |
nicklas |
141 |
|
11 |
13 Sep 07 |
nicklas |
/** Set the change p-value |
11 |
13 Sep 07 |
nicklas |
* @param p The change p-value. |
11 |
13 Sep 07 |
nicklas |
144 |
*/ |
11 |
13 Sep 07 |
nicklas |
145 |
public void setChangePValue(float p) { changePValue = p; } |
11 |
13 Sep 07 |
nicklas |
146 |
|
11 |
13 Sep 07 |
nicklas |
/** The signal log ratio */ |
11 |
13 Sep 07 |
nicklas |
148 |
private float signalLogRatio; |
11 |
13 Sep 07 |
nicklas |
149 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the signal log ratio. |
11 |
13 Sep 07 |
nicklas |
* @return The signal log ratio. |
11 |
13 Sep 07 |
nicklas |
152 |
*/ |
11 |
13 Sep 07 |
nicklas |
153 |
public float getSignalLogRatio() { return signalLogRatio; } |
11 |
13 Sep 07 |
nicklas |
154 |
|
11 |
13 Sep 07 |
nicklas |
/** Set the signal log ratio. |
11 |
13 Sep 07 |
nicklas |
* @param s The signal log ratio. |
11 |
13 Sep 07 |
nicklas |
157 |
*/ |
11 |
13 Sep 07 |
nicklas |
158 |
public void setSignalLogRatio(float s) { signalLogRatio = s; } |
11 |
13 Sep 07 |
nicklas |
159 |
|
11 |
13 Sep 07 |
nicklas |
/** The signal log ratio low value */ |
11 |
13 Sep 07 |
nicklas |
161 |
private float signalLogRatioLow; |
11 |
13 Sep 07 |
nicklas |
162 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the signal log ratio low. |
11 |
13 Sep 07 |
nicklas |
* @return The signal log ratio low. |
11 |
13 Sep 07 |
nicklas |
165 |
*/ |
11 |
13 Sep 07 |
nicklas |
166 |
public float getSignalLogRatioLow() { return signalLogRatioLow; } |
11 |
13 Sep 07 |
nicklas |
167 |
|
11 |
13 Sep 07 |
nicklas |
/** Set the signal log ratio low. |
11 |
13 Sep 07 |
nicklas |
* @param s The signal log ratio low. |
11 |
13 Sep 07 |
nicklas |
170 |
*/ |
11 |
13 Sep 07 |
nicklas |
171 |
public void setSignalLogRatioLow(float s) { signalLogRatioLow = s; } |
11 |
13 Sep 07 |
nicklas |
172 |
|
11 |
13 Sep 07 |
nicklas |
/** The signal log ratio high value */ |
11 |
13 Sep 07 |
nicklas |
174 |
private float signalLogRatioHigh; |
11 |
13 Sep 07 |
nicklas |
175 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the signal log ratio high. |
11 |
13 Sep 07 |
nicklas |
* @return The signal log ratio high. |
11 |
13 Sep 07 |
nicklas |
178 |
*/ |
11 |
13 Sep 07 |
nicklas |
179 |
public float getSignalLogRatioHigh() { return signalLogRatioHigh; } |
11 |
13 Sep 07 |
nicklas |
180 |
|
11 |
13 Sep 07 |
nicklas |
/** Set the signal log ratio high. |
11 |
13 Sep 07 |
nicklas |
* @param s The signal log ratio high. |
11 |
13 Sep 07 |
nicklas |
183 |
*/ |
11 |
13 Sep 07 |
nicklas |
184 |
public void setSignalLogRatioHigh(float s) { signalLogRatioHigh = s; } |
11 |
13 Sep 07 |
nicklas |
185 |
|
11 |
13 Sep 07 |
nicklas |
/** The number of probe pairs in common between the experiment and baseline data */ |
11 |
13 Sep 07 |
nicklas |
187 |
private short numCommonPairs; |
11 |
13 Sep 07 |
nicklas |
188 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the number of probe pairs in common between the experiment and baseline data. |
11 |
13 Sep 07 |
nicklas |
* @return The number of probe pairs in common between the experiment and baseline data. |
11 |
13 Sep 07 |
nicklas |
191 |
*/ |
11 |
13 Sep 07 |
nicklas |
192 |
public short getNumCommonPairs() { return numCommonPairs; } |
11 |
13 Sep 07 |
nicklas |
193 |
|
11 |
13 Sep 07 |
nicklas |
/** Set the number of probe pairs in common between the experiment and baseline data. |
11 |
13 Sep 07 |
nicklas |
* @param n The number of probe pairs in common between the experiment and baseline data. |
11 |
13 Sep 07 |
nicklas |
196 |
*/ |
11 |
13 Sep 07 |
nicklas |
197 |
public void setNumCommonPairs(short n) { numCommonPairs = n; } |
11 |
13 Sep 07 |
nicklas |
198 |
|
11 |
13 Sep 07 |
nicklas |
/** The change call */ |
11 |
13 Sep 07 |
nicklas |
200 |
private byte change; |
11 |
13 Sep 07 |
nicklas |
201 |
|
11 |
13 Sep 07 |
nicklas |
/** Gets the change call. |
11 |
13 Sep 07 |
nicklas |
* @return The change call. |
11 |
13 Sep 07 |
nicklas |
204 |
*/ |
11 |
13 Sep 07 |
nicklas |
205 |
public byte getChange() { return change; } |
11 |
13 Sep 07 |
nicklas |
206 |
|
11 |
13 Sep 07 |
nicklas |
/** Set the change call. |
11 |
13 Sep 07 |
nicklas |
* @param c The the change call. |
11 |
13 Sep 07 |
nicklas |
209 |
*/ |
11 |
13 Sep 07 |
nicklas |
210 |
public void setChange(byte c) { change = c; } |
11 |
13 Sep 07 |
nicklas |
211 |
|
11 |
13 Sep 07 |
nicklas |
/** Returns a string representation of the detection call. |
11 |
13 Sep 07 |
nicklas |
* @return The detection call |
11 |
13 Sep 07 |
nicklas |
214 |
*/ |
11 |
13 Sep 07 |
nicklas |
215 |
public String getDetectionString() |
11 |
13 Sep 07 |
nicklas |
216 |
{ |
11 |
13 Sep 07 |
nicklas |
217 |
switch (detection) |
11 |
13 Sep 07 |
nicklas |
218 |
{ |
11 |
13 Sep 07 |
nicklas |
219 |
case ABS_PRESENT_CALL: |
11 |
13 Sep 07 |
nicklas |
220 |
return "P"; |
11 |
13 Sep 07 |
nicklas |
221 |
|
11 |
13 Sep 07 |
nicklas |
222 |
case ABS_MARGINAL_CALL: |
11 |
13 Sep 07 |
nicklas |
223 |
return "M"; |
11 |
13 Sep 07 |
nicklas |
224 |
|
11 |
13 Sep 07 |
nicklas |
225 |
case ABS_ABSENT_CALL: |
11 |
13 Sep 07 |
nicklas |
226 |
return "A"; |
11 |
13 Sep 07 |
nicklas |
227 |
|
11 |
13 Sep 07 |
nicklas |
228 |
case ABS_NO_CALL: |
11 |
13 Sep 07 |
nicklas |
229 |
return "No Call"; |
11 |
13 Sep 07 |
nicklas |
230 |
|
11 |
13 Sep 07 |
nicklas |
231 |
default: |
11 |
13 Sep 07 |
nicklas |
232 |
return ""; |
11 |
13 Sep 07 |
nicklas |
233 |
} |
11 |
13 Sep 07 |
nicklas |
234 |
} |
11 |
13 Sep 07 |
nicklas |
235 |
|
11 |
13 Sep 07 |
nicklas |
/** Returns a string representation of the change call. |
11 |
13 Sep 07 |
nicklas |
* @return The change call |
11 |
13 Sep 07 |
nicklas |
238 |
*/ |
11 |
13 Sep 07 |
nicklas |
239 |
public String getChangeString() |
11 |
13 Sep 07 |
nicklas |
240 |
{ |
11 |
13 Sep 07 |
nicklas |
241 |
switch (change) |
11 |
13 Sep 07 |
nicklas |
242 |
{ |
11 |
13 Sep 07 |
nicklas |
243 |
case COMP_INCREASE_CALL: |
11 |
13 Sep 07 |
nicklas |
244 |
return "I"; |
11 |
13 Sep 07 |
nicklas |
245 |
|
11 |
13 Sep 07 |
nicklas |
246 |
case COMP_DECREASE_CALL: |
11 |
13 Sep 07 |
nicklas |
247 |
return "D"; |
11 |
13 Sep 07 |
nicklas |
248 |
|
11 |
13 Sep 07 |
nicklas |
249 |
case COMP_MOD_INCREASE_CALL: |
11 |
13 Sep 07 |
nicklas |
250 |
return "MI"; |
11 |
13 Sep 07 |
nicklas |
251 |
|
11 |
13 Sep 07 |
nicklas |
252 |
case COMP_MOD_DECREASE_CALL: |
11 |
13 Sep 07 |
nicklas |
253 |
return "MD"; |
11 |
13 Sep 07 |
nicklas |
254 |
|
11 |
13 Sep 07 |
nicklas |
255 |
case COMP_NO_CHANGE_CALL: |
11 |
13 Sep 07 |
nicklas |
256 |
return "NC"; |
11 |
13 Sep 07 |
nicklas |
257 |
|
11 |
13 Sep 07 |
nicklas |
258 |
case COMP_NO_CALL: |
11 |
13 Sep 07 |
nicklas |
259 |
return "No Call"; |
11 |
13 Sep 07 |
nicklas |
260 |
|
11 |
13 Sep 07 |
nicklas |
261 |
default: |
11 |
13 Sep 07 |
nicklas |
262 |
return ""; |
11 |
13 Sep 07 |
nicklas |
263 |
} |
11 |
13 Sep 07 |
nicklas |
264 |
} |
11 |
13 Sep 07 |
nicklas |
265 |
|
11 |
13 Sep 07 |
nicklas |
/** Creates a new instance of ExpressionProbeSetResults */ |
11 |
13 Sep 07 |
nicklas |
267 |
public ExpressionProbeSetResults() { |
11 |
13 Sep 07 |
nicklas |
268 |
detectionPValue=0.0f; |
11 |
13 Sep 07 |
nicklas |
269 |
signal=0.0f; |
11 |
13 Sep 07 |
nicklas |
270 |
numPairs=0; |
11 |
13 Sep 07 |
nicklas |
271 |
numUsedPairs=0; |
11 |
13 Sep 07 |
nicklas |
272 |
detection=ABS_NO_CALL; |
11 |
13 Sep 07 |
nicklas |
273 |
hasCompResults=false; |
11 |
13 Sep 07 |
nicklas |
274 |
changePValue=0.0f; |
11 |
13 Sep 07 |
nicklas |
275 |
signalLogRatio=0.0f; |
11 |
13 Sep 07 |
nicklas |
276 |
signalLogRatioLow=0.0f; |
11 |
13 Sep 07 |
nicklas |
277 |
signalLogRatioHigh=0.0f; |
11 |
13 Sep 07 |
nicklas |
278 |
numCommonPairs=0; |
11 |
13 Sep 07 |
nicklas |
279 |
change=COMP_NO_CALL; |
11 |
13 Sep 07 |
nicklas |
280 |
} |
11 |
13 Sep 07 |
nicklas |
281 |
} |