2 |
26 Feb 07 |
jari |
1 |
/* |
2 |
26 Feb 07 |
jari |
Copyright @ 1999-2004, The Institute for Genomic Research (TIGR). |
2 |
26 Feb 07 |
jari |
All rights reserved. |
2 |
26 Feb 07 |
jari |
4 |
*/ |
2 |
26 Feb 07 |
jari |
5 |
/* |
2 |
26 Feb 07 |
jari |
* $RCSfile: FStatsTableViewer.java,v $ |
2 |
26 Feb 07 |
jari |
* $Revision: 1.7 $ |
2 |
26 Feb 07 |
jari |
* $Date: 2006/03/24 15:51:02 $ |
2 |
26 Feb 07 |
jari |
* $Author: eleanorahowe $ |
2 |
26 Feb 07 |
jari |
* $State: Exp $ |
2 |
26 Feb 07 |
jari |
11 |
*/ |
2 |
26 Feb 07 |
jari |
12 |
package org.tigr.microarray.mev.cluster.gui.impl.owa; |
2 |
26 Feb 07 |
jari |
13 |
|
2 |
26 Feb 07 |
jari |
14 |
import java.awt.Color; |
2 |
26 Feb 07 |
jari |
15 |
import java.awt.Dimension; |
2 |
26 Feb 07 |
jari |
16 |
import java.awt.GridBagConstraints; |
2 |
26 Feb 07 |
jari |
17 |
import java.awt.GridBagLayout; |
2 |
26 Feb 07 |
jari |
18 |
import java.awt.event.ActionEvent; |
2 |
26 Feb 07 |
jari |
19 |
import java.awt.event.ActionListener; |
2 |
26 Feb 07 |
jari |
20 |
import java.awt.event.InputEvent; |
2 |
26 Feb 07 |
jari |
21 |
import java.awt.event.MouseAdapter; |
2 |
26 Feb 07 |
jari |
22 |
import java.awt.event.MouseEvent; |
2 |
26 Feb 07 |
jari |
23 |
import java.io.File; |
2 |
26 Feb 07 |
jari |
24 |
import java.io.FileOutputStream; |
2 |
26 Feb 07 |
jari |
25 |
import java.io.PrintWriter; |
2 |
26 Feb 07 |
jari |
26 |
import java.util.Arrays; |
2 |
26 Feb 07 |
jari |
27 |
import java.util.Vector; |
2 |
26 Feb 07 |
jari |
28 |
|
2 |
26 Feb 07 |
jari |
29 |
import javax.swing.JComponent; |
2 |
26 Feb 07 |
jari |
30 |
import javax.swing.JFileChooser; |
2 |
26 Feb 07 |
jari |
31 |
import javax.swing.JMenuItem; |
2 |
26 Feb 07 |
jari |
32 |
import javax.swing.JPanel; |
2 |
26 Feb 07 |
jari |
33 |
import javax.swing.JPopupMenu; |
2 |
26 Feb 07 |
jari |
34 |
import javax.swing.JTable; |
2 |
26 Feb 07 |
jari |
35 |
import javax.swing.table.AbstractTableModel; |
2 |
26 Feb 07 |
jari |
36 |
import javax.swing.table.JTableHeader; |
2 |
26 Feb 07 |
jari |
37 |
import javax.swing.table.TableColumn; |
2 |
26 Feb 07 |
jari |
38 |
import javax.swing.table.TableColumnModel; |
2 |
26 Feb 07 |
jari |
39 |
|
2 |
26 Feb 07 |
jari |
40 |
import org.tigr.microarray.mev.cluster.gui.Experiment; |
2 |
26 Feb 07 |
jari |
41 |
import org.tigr.microarray.mev.cluster.gui.IData; |
2 |
26 Feb 07 |
jari |
42 |
import org.tigr.microarray.mev.cluster.gui.impl.GUIFactory; |
2 |
26 Feb 07 |
jari |
43 |
import org.tigr.microarray.mev.cluster.gui.impl.ViewerAdapter; |
2 |
26 Feb 07 |
jari |
44 |
import org.tigr.util.QSort; |
2 |
26 Feb 07 |
jari |
45 |
|
2 |
26 Feb 07 |
jari |
46 |
/** |
2 |
26 Feb 07 |
jari |
47 |
* |
2 |
26 Feb 07 |
jari |
* @author nbhagaba |
2 |
26 Feb 07 |
jari |
* @version |
2 |
26 Feb 07 |
jari |
50 |
*/ |
2 |
26 Feb 07 |
jari |
51 |
public class FStatsTableViewer extends ViewerAdapter implements java.io.Serializable { |
2 |
26 Feb 07 |
jari |
52 |
public static final long serialVersionUID = 202010010001L; |
2 |
26 Feb 07 |
jari |
53 |
|
2 |
26 Feb 07 |
jari |
54 |
private JComponent header; |
2 |
26 Feb 07 |
jari |
55 |
private JComponent content; |
2 |
26 Feb 07 |
jari |
56 |
private Experiment experiment; |
2 |
26 Feb 07 |
jari |
57 |
private int[][] clusters; |
2 |
26 Feb 07 |
jari |
58 |
private boolean sig; |
2 |
26 Feb 07 |
jari |
59 |
private int[] rows; |
2 |
26 Feb 07 |
jari |
60 |
private String[] fieldNames; |
2 |
26 Feb 07 |
jari |
61 |
|
2 |
26 Feb 07 |
jari |
62 |
private FValuesTableModel fModel; |
2 |
26 Feb 07 |
jari |
63 |
private JTable fValuesTable; |
2 |
26 Feb 07 |
jari |
64 |
|
2 |
26 Feb 07 |
jari |
65 |
private Vector pValues, fValues, dfNumValues, dfDenomValues, ssGroups, ssError; |
2 |
26 Feb 07 |
jari |
66 |
private float[][] geneGroupMeans, geneGroupSDs; |
2 |
26 Feb 07 |
jari |
67 |
private IData data; |
2 |
26 Feb 07 |
jari |
68 |
private JPopupMenu popup; |
2 |
26 Feb 07 |
jari |
69 |
private Object[][] origData; |
2 |
26 Feb 07 |
jari |
70 |
private int univCnt, univCnt2, univCnt3; |
2 |
26 Feb 07 |
jari |
71 |
private boolean sortedAscending[]; |
2 |
26 Feb 07 |
jari |
72 |
|
2 |
26 Feb 07 |
jari |
/** Creates new FStatsTableViewer */ |
2 |
26 Feb 07 |
jari |
74 |
public FStatsTableViewer(Experiment experiment, int[][] clusters, IData data, float[][] geneGroupMeans, float[][] geneGroupSDs, Vector pValues, Vector fValues, Vector ssGroups, Vector ssError, Vector dfNumValues, Vector dfDenomValues, boolean sig) { |
2 |
26 Feb 07 |
jari |
75 |
this.experiment = experiment; |
2 |
26 Feb 07 |
jari |
76 |
this.clusters = clusters; |
2 |
26 Feb 07 |
jari |
77 |
this.data = data; |
2 |
26 Feb 07 |
jari |
78 |
fieldNames = data.getFieldNames(); |
2 |
26 Feb 07 |
jari |
79 |
this.geneGroupMeans = geneGroupMeans; |
2 |
26 Feb 07 |
jari |
80 |
this.geneGroupSDs = geneGroupSDs; |
2 |
26 Feb 07 |
jari |
81 |
this.pValues = pValues; |
2 |
26 Feb 07 |
jari |
82 |
this.fValues = fValues; |
2 |
26 Feb 07 |
jari |
83 |
this.ssGroups = ssGroups; |
2 |
26 Feb 07 |
jari |
84 |
this.ssError = ssError; |
2 |
26 Feb 07 |
jari |
85 |
this.dfNumValues = dfNumValues; |
2 |
26 Feb 07 |
jari |
86 |
this.dfDenomValues = dfDenomValues; |
2 |
26 Feb 07 |
jari |
87 |
this.sig = sig; |
2 |
26 Feb 07 |
jari |
88 |
if (sig) { |
2 |
26 Feb 07 |
jari |
89 |
rows = clusters[0]; |
2 |
26 Feb 07 |
jari |
90 |
} else { |
2 |
26 Feb 07 |
jari |
91 |
rows =clusters[1]; |
2 |
26 Feb 07 |
jari |
92 |
} |
2 |
26 Feb 07 |
jari |
93 |
|
2 |
26 Feb 07 |
jari |
94 |
fModel = new FValuesTableModel(); |
2 |
26 Feb 07 |
jari |
95 |
fValuesTable = new JTable(fModel); |
2 |
26 Feb 07 |
jari |
96 |
origData = new Object[fModel.getRowCount()][fModel.getColumnCount()]; |
2 |
26 Feb 07 |
jari |
97 |
for (int i = 0; i < origData.length; i++) { |
2 |
26 Feb 07 |
jari |
98 |
for (int j = 0; j < origData[i].length; j++) { |
2 |
26 Feb 07 |
jari |
99 |
origData[i][j] = fModel.getValueAt(i, j); |
2 |
26 Feb 07 |
jari |
100 |
} |
2 |
26 Feb 07 |
jari |
101 |
} |
2 |
26 Feb 07 |
jari |
102 |
this.sortedAscending = new boolean[fModel.getColumnCount()]; |
2 |
26 Feb 07 |
jari |
103 |
for (int i = 0; i < sortedAscending.length; i++) { |
2 |
26 Feb 07 |
jari |
104 |
sortedAscending[i] = false; |
2 |
26 Feb 07 |
jari |
105 |
} |
2 |
26 Feb 07 |
jari |
106 |
TableColumn column = null; |
2 |
26 Feb 07 |
jari |
107 |
for (int i = 0; i < fModel.getColumnCount(); i++) { |
2 |
26 Feb 07 |
jari |
108 |
column = fValuesTable.getColumnModel().getColumn(i); |
2 |
26 Feb 07 |
jari |
109 |
column.setMinWidth(30); |
2 |
26 Feb 07 |
jari |
110 |
} |
2 |
26 Feb 07 |
jari |
111 |
addMouseListenerToHeaderInTable(fValuesTable); |
2 |
26 Feb 07 |
jari |
112 |
header = fValuesTable.getTableHeader(); |
2 |
26 Feb 07 |
jari |
113 |
setMaxWidth(getContentComponent(), getHeaderComponent()); |
2 |
26 Feb 07 |
jari |
114 |
} |
2 |
26 Feb 07 |
jari |
115 |
|
2 |
26 Feb 07 |
jari |
116 |
public FStatsTableViewer(JComponent content, JComponent header){ |
2 |
26 Feb 07 |
jari |
117 |
this.content = content; |
2 |
26 Feb 07 |
jari |
118 |
this.header = header; |
2 |
26 Feb 07 |
jari |
119 |
setMaxWidth(getContentComponent(), getHeaderComponent()); |
2 |
26 Feb 07 |
jari |
120 |
} |
2 |
26 Feb 07 |
jari |
121 |
|
2 |
26 Feb 07 |
jari |
122 |
|
2 |
26 Feb 07 |
jari |
123 |
|
2 |
26 Feb 07 |
jari |
124 |
/** |
2 |
26 Feb 07 |
jari |
* Returns component to be inserted into the framework scroll pane. |
2 |
26 Feb 07 |
jari |
126 |
*/ |
2 |
26 Feb 07 |
jari |
127 |
public JComponent getContentComponent() { |
2 |
26 Feb 07 |
jari |
128 |
JPanel panel = new JPanel(); |
2 |
26 Feb 07 |
jari |
129 |
panel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
130 |
GridBagConstraints constraints = new GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
131 |
GridBagLayout gridbag = new GridBagLayout(); |
2 |
26 Feb 07 |
jari |
132 |
panel.setLayout(gridbag); |
2 |
26 Feb 07 |
jari |
133 |
constraints.fill = GridBagConstraints.HORIZONTAL; |
2 |
26 Feb 07 |
jari |
134 |
constraints.anchor = GridBagConstraints.NORTH; |
2 |
26 Feb 07 |
jari |
135 |
buildConstraints(constraints, 0, 0, 1, 1, 100, 100); |
2 |
26 Feb 07 |
jari |
136 |
gridbag.setConstraints(fValuesTable, constraints); |
2 |
26 Feb 07 |
jari |
137 |
panel.add(fValuesTable); |
2 |
26 Feb 07 |
jari |
138 |
|
2 |
26 Feb 07 |
jari |
139 |
final JFileChooser fc = new JFileChooser(); |
2 |
26 Feb 07 |
jari |
140 |
fc.setCurrentDirectory(new File("Data")); |
2 |
26 Feb 07 |
jari |
141 |
fc.setDialogTitle("Save F-Ratio information"); |
2 |
26 Feb 07 |
jari |
142 |
|
2 |
26 Feb 07 |
jari |
143 |
popup = new JPopupMenu(); |
2 |
26 Feb 07 |
jari |
144 |
JMenuItem menuItem = new JMenuItem("Save F-Ratio information", GUIFactory.getIcon("save16.gif")); |
2 |
26 Feb 07 |
jari |
145 |
menuItem.addActionListener(new ActionListener() { |
2 |
26 Feb 07 |
jari |
146 |
public void actionPerformed(ActionEvent evt) { |
2 |
26 Feb 07 |
jari |
147 |
int returnVal = fc.showSaveDialog(FStatsTableViewer.this.getHeaderComponent()); |
2 |
26 Feb 07 |
jari |
148 |
if (returnVal == JFileChooser.APPROVE_OPTION) { |
2 |
26 Feb 07 |
jari |
149 |
File file = fc.getSelectedFile(); |
2 |
26 Feb 07 |
jari |
150 |
try { |
2 |
26 Feb 07 |
jari |
151 |
PrintWriter out = new PrintWriter(new FileOutputStream(file)); |
2 |
26 Feb 07 |
jari |
152 |
for (int i = 0; i < fieldNames.length; i++) { |
2 |
26 Feb 07 |
jari |
153 |
out.print(fieldNames[i]); |
2 |
26 Feb 07 |
jari |
//if (i < fieldNames.length - 1) { |
2 |
26 Feb 07 |
jari |
155 |
|
2 |
26 Feb 07 |
jari |
156 |
out.print("\t"); |
2 |
26 Feb 07 |
jari |
157 |
//} |
2 |
26 Feb 07 |
jari |
158 |
} |
2 |
26 Feb 07 |
jari |
159 |
for (int i = 0; i < geneGroupMeans[0].length; i++) { |
2 |
26 Feb 07 |
jari |
160 |
out.print("Group" + (i+1) + " mean\t"); |
2 |
26 Feb 07 |
jari |
161 |
out.print("Group" + (i + 1) + " std.dev.\t"); |
2 |
26 Feb 07 |
jari |
162 |
} |
2 |
26 Feb 07 |
jari |
163 |
out.print("F-ratio\tSS(Groups)\tSS(Error)\tdf(Groups)\tdf(Error)\tp-value\n"); |
2 |
26 Feb 07 |
jari |
164 |
for (int i = 0; i < rows.length; i++) { |
2 |
26 Feb 07 |
jari |
165 |
for (int k = 0; k < fieldNames.length; k++) { |
2 |
26 Feb 07 |
jari |
166 |
out.print(data.getElementAttribute(experiment.getGeneIndexMappedToData(rows[i]), k)); |
2 |
26 Feb 07 |
jari |
//if (k < fieldNames.length - 1) { |
2 |
26 Feb 07 |
jari |
168 |
out.print("\t"); |
2 |
26 Feb 07 |
jari |
169 |
//} |
2 |
26 Feb 07 |
jari |
170 |
} |
2 |
26 Feb 07 |
jari |
171 |
for (int j = 0; j < geneGroupMeans[i].length; j++) { |
2 |
26 Feb 07 |
jari |
172 |
out.print(geneGroupMeans[rows[i]][j] + "\t"); |
2 |
26 Feb 07 |
jari |
173 |
out.print(geneGroupSDs[rows[i]][j] + "\t"); |
2 |
26 Feb 07 |
jari |
174 |
} |
2 |
26 Feb 07 |
jari |
175 |
out.print(((Float)(fValues.get(rows[i]))).floatValue()); |
2 |
26 Feb 07 |
jari |
176 |
out.print("\t" + ((Float)(ssGroups.get(rows[i]))).floatValue()); |
2 |
26 Feb 07 |
jari |
177 |
out.print("\t" + ((Float)(ssError.get(rows[i]))).floatValue()); |
2 |
26 Feb 07 |
jari |
178 |
out.print("\t" + ((Float)(dfNumValues.get(rows[i]))).intValue()); |
2 |
26 Feb 07 |
jari |
179 |
out.print("\t" + ((Float)(dfDenomValues.get(rows[i]))).intValue()); |
2 |
26 Feb 07 |
jari |
180 |
out.print("\t" + ((Float)(pValues.get(rows[i]))).floatValue()); |
2 |
26 Feb 07 |
jari |
181 |
out.print("\n"); |
2 |
26 Feb 07 |
jari |
182 |
} |
2 |
26 Feb 07 |
jari |
183 |
out.println(); |
2 |
26 Feb 07 |
jari |
184 |
out.flush(); |
2 |
26 Feb 07 |
jari |
185 |
out.close(); |
2 |
26 Feb 07 |
jari |
186 |
} catch (Exception e) { |
2 |
26 Feb 07 |
jari |
//e.printStackTrace(); |
2 |
26 Feb 07 |
jari |
188 |
} |
2 |
26 Feb 07 |
jari |
//this is where a real application would save the file. |
2 |
26 Feb 07 |
jari |
//log.append("Saving: " + file.getName() + "." + newline); |
2 |
26 Feb 07 |
jari |
191 |
} else { |
2 |
26 Feb 07 |
jari |
//log.append("Save command cancelled by user." + newline); |
2 |
26 Feb 07 |
jari |
193 |
} |
2 |
26 Feb 07 |
jari |
194 |
} |
2 |
26 Feb 07 |
jari |
195 |
}); |
2 |
26 Feb 07 |
jari |
196 |
|
2 |
26 Feb 07 |
jari |
197 |
popup.add(menuItem); |
2 |
26 Feb 07 |
jari |
198 |
|
2 |
26 Feb 07 |
jari |
199 |
fValuesTable.addMouseListener(new MouseAdapter() { |
2 |
26 Feb 07 |
jari |
200 |
public void mousePressed(MouseEvent e) { |
2 |
26 Feb 07 |
jari |
201 |
maybeShowPopup(e); |
2 |
26 Feb 07 |
jari |
202 |
} |
2 |
26 Feb 07 |
jari |
203 |
|
2 |
26 Feb 07 |
jari |
204 |
public void mouseReleased(MouseEvent e) { |
2 |
26 Feb 07 |
jari |
205 |
maybeShowPopup(e); |
2 |
26 Feb 07 |
jari |
206 |
} |
2 |
26 Feb 07 |
jari |
207 |
|
2 |
26 Feb 07 |
jari |
208 |
private void maybeShowPopup(MouseEvent e) { |
2 |
26 Feb 07 |
jari |
209 |
if (e.isPopupTrigger()) { |
2 |
26 Feb 07 |
jari |
210 |
popup.show(e.getComponent(), |
2 |
26 Feb 07 |
jari |
211 |
e.getX(), e.getY()); |
2 |
26 Feb 07 |
jari |
212 |
} |
2 |
26 Feb 07 |
jari |
213 |
} |
2 |
26 Feb 07 |
jari |
214 |
|
2 |
26 Feb 07 |
jari |
215 |
}); |
2 |
26 Feb 07 |
jari |
216 |
|
2 |
26 Feb 07 |
jari |
217 |
return panel; |
2 |
26 Feb 07 |
jari |
218 |
} |
2 |
26 Feb 07 |
jari |
219 |
|
2 |
26 Feb 07 |
jari |
220 |
/** |
2 |
26 Feb 07 |
jari |
* Returns the viewer header. |
2 |
26 Feb 07 |
jari |
222 |
*/ |
2 |
26 Feb 07 |
jari |
223 |
public JComponent getHeaderComponent() { |
2 |
26 Feb 07 |
jari |
224 |
JPanel panel = new JPanel(); |
2 |
26 Feb 07 |
jari |
225 |
panel.setBackground(Color.white); |
2 |
26 Feb 07 |
jari |
226 |
GridBagConstraints constraints = new GridBagConstraints(); |
2 |
26 Feb 07 |
jari |
227 |
GridBagLayout gridbag = new GridBagLayout(); |
2 |
26 Feb 07 |
jari |
228 |
panel.setLayout(gridbag); |
2 |
26 Feb 07 |
jari |
229 |
constraints.fill = GridBagConstraints.HORIZONTAL; |
2 |
26 Feb 07 |
jari |
230 |
buildConstraints(constraints, 0, 0, 1, 1, 100, 100); |
2 |
26 Feb 07 |
jari |
231 |
gridbag.setConstraints(header, constraints); |
2 |
26 Feb 07 |
jari |
232 |
panel.add(header); |
2 |
26 Feb 07 |
jari |
233 |
return panel; |
2 |
26 Feb 07 |
jari |
//return header; |
2 |
26 Feb 07 |
jari |
235 |
} |
2 |
26 Feb 07 |
jari |
236 |
|
2 |
26 Feb 07 |
jari |
237 |
void buildConstraints(GridBagConstraints gbc, int gx, int gy, |
2 |
26 Feb 07 |
jari |
238 |
int gw, int gh, int wx, int wy) { |
2 |
26 Feb 07 |
jari |
239 |
|
2 |
26 Feb 07 |
jari |
240 |
gbc.gridx = gx; |
2 |
26 Feb 07 |
jari |
241 |
gbc.gridy = gy; |
2 |
26 Feb 07 |
jari |
242 |
gbc.gridwidth = gw; |
2 |
26 Feb 07 |
jari |
243 |
gbc.gridheight = gh; |
2 |
26 Feb 07 |
jari |
244 |
gbc.weightx = wx; |
2 |
26 Feb 07 |
jari |
245 |
gbc.weighty = wy; |
2 |
26 Feb 07 |
jari |
246 |
} |
2 |
26 Feb 07 |
jari |
247 |
|
2 |
26 Feb 07 |
jari |
248 |
|
2 |
26 Feb 07 |
jari |
249 |
class FValuesTableModel extends AbstractTableModel { |
2 |
26 Feb 07 |
jari |
250 |
String[] columnNames; |
2 |
26 Feb 07 |
jari |
251 |
Object[][] tableData; |
2 |
26 Feb 07 |
jari |
252 |
|
2 |
26 Feb 07 |
jari |
253 |
public FValuesTableModel() { |
2 |
26 Feb 07 |
jari |
254 |
columnNames = new String[fieldNames.length + 2*geneGroupMeans[0].length + 6]; |
2 |
26 Feb 07 |
jari |
255 |
int counter; |
2 |
26 Feb 07 |
jari |
256 |
for (counter = 0; counter < fieldNames.length; counter++) { |
2 |
26 Feb 07 |
jari |
257 |
columnNames[counter] = fieldNames[counter]; |
2 |
26 Feb 07 |
jari |
258 |
} |
2 |
26 Feb 07 |
jari |
259 |
univCnt = counter; |
2 |
26 Feb 07 |
jari |
260 |
int counter2; |
2 |
26 Feb 07 |
jari |
261 |
int groupNum = 1; |
2 |
26 Feb 07 |
jari |
262 |
for (counter2 = 0; counter2 < 2*geneGroupMeans[0].length; counter2++) { |
2 |
26 Feb 07 |
jari |
263 |
columnNames[counter + counter2] = "Group" + groupNum + " mean"; |
2 |
26 Feb 07 |
jari |
264 |
counter2++; |
2 |
26 Feb 07 |
jari |
265 |
columnNames[counter + counter2] = "Group" + groupNum + " std.dev."; |
2 |
26 Feb 07 |
jari |
266 |
groupNum++; |
2 |
26 Feb 07 |
jari |
267 |
} |
2 |
26 Feb 07 |
jari |
268 |
univCnt2 = counter2; |
2 |
26 Feb 07 |
jari |
269 |
int counter3 = counter + counter2; |
2 |
26 Feb 07 |
jari |
270 |
univCnt3 = counter3; |
2 |
26 Feb 07 |
jari |
271 |
columnNames[counter3] = "F-Ratio"; |
2 |
26 Feb 07 |
jari |
272 |
columnNames[counter3 + 1] = "SS (Groups)"; |
2 |
26 Feb 07 |
jari |
273 |
columnNames[counter3 + 2] = "SS (Error)"; |
2 |
26 Feb 07 |
jari |
274 |
columnNames[counter3 + 3] = "df (Groups)"; |
2 |
26 Feb 07 |
jari |
275 |
columnNames[counter3 + 4] = "df (Error)"; |
2 |
26 Feb 07 |
jari |
276 |
columnNames[counter3 + 5] = "p-value"; |
2 |
26 Feb 07 |
jari |
277 |
|
2 |
26 Feb 07 |
jari |
278 |
tableData = new Object[rows.length][columnNames.length]; |
2 |
26 Feb 07 |
jari |
279 |
|
2 |
26 Feb 07 |
jari |
//groupNum = 0; |
2 |
26 Feb 07 |
jari |
//System.out.println("counter = " + counter + ", counter3 = " + counter3); |
2 |
26 Feb 07 |
jari |
282 |
for (int i = 0; i < tableData.length; i++) { |
2 |
26 Feb 07 |
jari |
283 |
groupNum = 0; |
2 |
26 Feb 07 |
jari |
284 |
for (int j = counter; j < counter3;) { |
2 |
26 Feb 07 |
jari |
//if ((j >= counter) && (j < counter3)) { |
2 |
26 Feb 07 |
jari |
//System.out.println("i = " + i + ", j = " + j + ", groupNum = " + groupNum); |
2 |
26 Feb 07 |
jari |
287 |
if (Float.isNaN(geneGroupMeans[rows[i]][groupNum])) { |
2 |
26 Feb 07 |
jari |
288 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
289 |
} else { |
2 |
26 Feb 07 |
jari |
290 |
tableData[i][j] = new Float(geneGroupMeans[rows[i]][groupNum]); |
2 |
26 Feb 07 |
jari |
291 |
} |
2 |
26 Feb 07 |
jari |
292 |
j++; |
2 |
26 Feb 07 |
jari |
293 |
|
2 |
26 Feb 07 |
jari |
294 |
if (Float.isNaN(geneGroupSDs[rows[i]][groupNum])) { |
2 |
26 Feb 07 |
jari |
295 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
296 |
} else { |
2 |
26 Feb 07 |
jari |
297 |
tableData[i][j] = new Float(geneGroupSDs[rows[i]][groupNum]); |
2 |
26 Feb 07 |
jari |
298 |
} |
2 |
26 Feb 07 |
jari |
299 |
groupNum++; |
2 |
26 Feb 07 |
jari |
300 |
j++; |
2 |
26 Feb 07 |
jari |
301 |
//} |
2 |
26 Feb 07 |
jari |
302 |
} |
2 |
26 Feb 07 |
jari |
303 |
} |
2 |
26 Feb 07 |
jari |
304 |
|
2 |
26 Feb 07 |
jari |
305 |
|
2 |
26 Feb 07 |
jari |
306 |
for (int i = 0; i < tableData.length; i++) { |
2 |
26 Feb 07 |
jari |
307 |
for (int j = 0; j < tableData[i].length; j++) { |
2 |
26 Feb 07 |
jari |
308 |
if (j < counter) { |
2 |
26 Feb 07 |
jari |
309 |
tableData[i][j] = data.getElementAttribute(experiment.getGeneIndexMappedToData(rows[i]), j); |
2 |
26 Feb 07 |
jari |
310 |
} else if ((j >= counter) && (j < counter3)) { |
2 |
26 Feb 07 |
jari |
//do nothing |
2 |
26 Feb 07 |
jari |
312 |
} else if (j == counter3) { |
2 |
26 Feb 07 |
jari |
313 |
float f = ((Float)(fValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
314 |
if (Float.isNaN(f)) { |
2 |
26 Feb 07 |
jari |
315 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
316 |
} else { |
2 |
26 Feb 07 |
jari |
317 |
tableData[i][j] = (Float)(fValues.get(rows[i])); |
2 |
26 Feb 07 |
jari |
318 |
} |
2 |
26 Feb 07 |
jari |
319 |
|
2 |
26 Feb 07 |
jari |
320 |
} else if (j == counter3 + 1) { |
2 |
26 Feb 07 |
jari |
321 |
|
2 |
26 Feb 07 |
jari |
322 |
float f = ((Float)(ssGroups.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
323 |
if (Float.isNaN(f)) { |
2 |
26 Feb 07 |
jari |
324 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
325 |
} else { |
2 |
26 Feb 07 |
jari |
326 |
tableData[i][j] = (Float)(ssGroups.get(rows[i])); |
2 |
26 Feb 07 |
jari |
327 |
} |
2 |
26 Feb 07 |
jari |
328 |
|
2 |
26 Feb 07 |
jari |
329 |
} else if (j == counter3 + 2) { |
2 |
26 Feb 07 |
jari |
330 |
|
2 |
26 Feb 07 |
jari |
331 |
float f = ((Float)(ssError.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
332 |
if (Float.isNaN(f)) { |
2 |
26 Feb 07 |
jari |
333 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
334 |
} else { |
2 |
26 Feb 07 |
jari |
335 |
tableData[i][j] = (Float)(ssError.get(rows[i])); |
2 |
26 Feb 07 |
jari |
336 |
} |
2 |
26 Feb 07 |
jari |
337 |
|
2 |
26 Feb 07 |
jari |
338 |
} else if (j == counter3 + 3) { |
2 |
26 Feb 07 |
jari |
339 |
|
2 |
26 Feb 07 |
jari |
340 |
float f = ((Float)(dfNumValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
341 |
if (Float.isNaN(f)) { |
2 |
26 Feb 07 |
jari |
342 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
343 |
} else { |
2 |
26 Feb 07 |
jari |
344 |
tableData[i][j] = (Float)(dfNumValues.get(rows[i])); |
2 |
26 Feb 07 |
jari |
345 |
} |
2 |
26 Feb 07 |
jari |
346 |
|
2 |
26 Feb 07 |
jari |
347 |
} else if (j == counter3 + 4) { |
2 |
26 Feb 07 |
jari |
348 |
float f = ((Float)(dfDenomValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
349 |
if (Float.isNaN(f)) { |
2 |
26 Feb 07 |
jari |
350 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
351 |
} else { |
2 |
26 Feb 07 |
jari |
352 |
tableData[i][j] = (Float)(dfDenomValues.get(rows[i])); |
2 |
26 Feb 07 |
jari |
353 |
} |
2 |
26 Feb 07 |
jari |
354 |
} else if (j == counter3 + 5) { |
2 |
26 Feb 07 |
jari |
355 |
float f = ((Float)(pValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
356 |
if (Float.isNaN(f)) { |
2 |
26 Feb 07 |
jari |
357 |
tableData[i][j] = "N/A"; |
2 |
26 Feb 07 |
jari |
358 |
} else { |
2 |
26 Feb 07 |
jari |
359 |
tableData[i][j] = (Float)(pValues.get(rows[i])); |
2 |
26 Feb 07 |
jari |
360 |
} |
2 |
26 Feb 07 |
jari |
361 |
} |
2 |
26 Feb 07 |
jari |
362 |
} |
2 |
26 Feb 07 |
jari |
363 |
} |
2 |
26 Feb 07 |
jari |
364 |
} |
2 |
26 Feb 07 |
jari |
365 |
|
2 |
26 Feb 07 |
jari |
366 |
public int getColumnCount() { |
2 |
26 Feb 07 |
jari |
367 |
return columnNames.length; |
2 |
26 Feb 07 |
jari |
368 |
} |
2 |
26 Feb 07 |
jari |
369 |
|
2 |
26 Feb 07 |
jari |
370 |
public int getRowCount() { |
2 |
26 Feb 07 |
jari |
371 |
return tableData.length; |
2 |
26 Feb 07 |
jari |
372 |
} |
2 |
26 Feb 07 |
jari |
373 |
|
2 |
26 Feb 07 |
jari |
374 |
public String getColumnName(int col) { |
2 |
26 Feb 07 |
jari |
375 |
return columnNames[col]; |
2 |
26 Feb 07 |
jari |
376 |
} |
2 |
26 Feb 07 |
jari |
377 |
|
2 |
26 Feb 07 |
jari |
378 |
public Object getValueAt(int row, int col) { |
2 |
26 Feb 07 |
jari |
379 |
return tableData[row][col]; |
2 |
26 Feb 07 |
jari |
380 |
} |
2 |
26 Feb 07 |
jari |
381 |
|
2 |
26 Feb 07 |
jari |
382 |
public void setValueAt(Object value, int row, int col) { |
2 |
26 Feb 07 |
jari |
383 |
tableData[row][col] = value; |
2 |
26 Feb 07 |
jari |
384 |
fireTableCellUpdated(row, col); |
2 |
26 Feb 07 |
jari |
385 |
} |
2 |
26 Feb 07 |
jari |
386 |
/* |
2 |
26 Feb 07 |
jari |
public Class getColumnClass(int c) { |
2 |
26 Feb 07 |
jari |
if (c < fieldNames.length) { |
2 |
26 Feb 07 |
jari |
return (new String()).getClass(); |
2 |
26 Feb 07 |
jari |
} else { |
2 |
26 Feb 07 |
jari |
return (new Float(1.0f)).getClass(); |
2 |
26 Feb 07 |
jari |
392 |
} |
2 |
26 Feb 07 |
jari |
//return getValueAt(0, c).getClass(); |
2 |
26 Feb 07 |
jari |
394 |
} |
2 |
26 Feb 07 |
jari |
395 |
*/ |
2 |
26 Feb 07 |
jari |
396 |
} |
2 |
26 Feb 07 |
jari |
397 |
|
2 |
26 Feb 07 |
jari |
398 |
|
2 |
26 Feb 07 |
jari |
399 |
/** |
2 |
26 Feb 07 |
jari |
* Synchronize content and header sizes. |
2 |
26 Feb 07 |
jari |
401 |
*/ |
2 |
26 Feb 07 |
jari |
402 |
private void setMaxWidth(JComponent content, JComponent header) { |
2 |
26 Feb 07 |
jari |
403 |
int c_width = content.getPreferredSize().width; |
2 |
26 Feb 07 |
jari |
404 |
int h_width = header.getPreferredSize().width; |
2 |
26 Feb 07 |
jari |
405 |
if (c_width > h_width) { |
2 |
26 Feb 07 |
jari |
406 |
header.setPreferredSize(new Dimension(c_width, header.getPreferredSize().height)); |
2 |
26 Feb 07 |
jari |
407 |
} else { |
2 |
26 Feb 07 |
jari |
408 |
content.setPreferredSize(new Dimension(h_width, content.getPreferredSize().height)); |
2 |
26 Feb 07 |
jari |
409 |
} |
2 |
26 Feb 07 |
jari |
410 |
} |
2 |
26 Feb 07 |
jari |
411 |
|
2 |
26 Feb 07 |
jari |
412 |
public void addMouseListenerToHeaderInTable(JTable table) { |
2 |
26 Feb 07 |
jari |
//final TableSorter sorter = this; |
2 |
26 Feb 07 |
jari |
414 |
final JTable tableView = table; |
2 |
26 Feb 07 |
jari |
415 |
tableView.setColumnSelectionAllowed(false); |
2 |
26 Feb 07 |
jari |
416 |
MouseAdapter listMouseListener = new MouseAdapter() { |
2 |
26 Feb 07 |
jari |
417 |
public void mouseClicked(MouseEvent e) { |
2 |
26 Feb 07 |
jari |
418 |
TableColumnModel columnModel = tableView.getColumnModel(); |
2 |
26 Feb 07 |
jari |
419 |
int viewColumn = columnModel.getColumnIndexAtX(e.getX()); |
2 |
26 Feb 07 |
jari |
420 |
int column = tableView.convertColumnIndexToModel(viewColumn); |
2 |
26 Feb 07 |
jari |
421 |
if (e.getClickCount() == 1 && column != -1) { |
2 |
26 Feb 07 |
jari |
//System.out.println("Sorting ..."); |
2 |
26 Feb 07 |
jari |
423 |
int shiftPressed = e.getModifiers()&InputEvent.SHIFT_MASK; |
2 |
26 Feb 07 |
jari |
424 |
int controlPressed = e.getModifiers()&InputEvent.CTRL_MASK; |
2 |
26 Feb 07 |
jari |
//boolean ascending = (shiftPressed == 0); |
2 |
26 Feb 07 |
jari |
426 |
boolean originalOrder = (controlPressed != 0); |
2 |
26 Feb 07 |
jari |
427 |
sortByColumn(column, !(sortedAscending[column]), originalOrder); |
2 |
26 Feb 07 |
jari |
428 |
sortedAscending[column] = !(sortedAscending[column]); |
2 |
26 Feb 07 |
jari |
429 |
if (originalOrder) { |
2 |
26 Feb 07 |
jari |
430 |
for (int i = 0; i < fModel.getColumnCount(); i++) |
2 |
26 Feb 07 |
jari |
431 |
sortedAscending[i] = false; |
2 |
26 Feb 07 |
jari |
432 |
} |
2 |
26 Feb 07 |
jari |
//sortByColumn(column, ascending, originalOrder); |
2 |
26 Feb 07 |
jari |
434 |
} |
2 |
26 Feb 07 |
jari |
435 |
} |
2 |
26 Feb 07 |
jari |
436 |
}; |
2 |
26 Feb 07 |
jari |
437 |
JTableHeader th = tableView.getTableHeader(); |
2 |
26 Feb 07 |
jari |
438 |
th.addMouseListener(listMouseListener); |
2 |
26 Feb 07 |
jari |
439 |
} |
2 |
26 Feb 07 |
jari |
440 |
|
2 |
26 Feb 07 |
jari |
441 |
public void sortByColumn(int column, boolean ascending, boolean originalOrder) { |
2 |
26 Feb 07 |
jari |
442 |
if (originalOrder) { |
2 |
26 Feb 07 |
jari |
443 |
for (int i = 0; i < fModel.getRowCount(); i++) { |
2 |
26 Feb 07 |
jari |
444 |
for (int j = 0; j < fModel.getColumnCount(); j++) { |
2 |
26 Feb 07 |
jari |
445 |
fModel.setValueAt(origData[i][j], i, j); |
2 |
26 Feb 07 |
jari |
446 |
} |
2 |
26 Feb 07 |
jari |
447 |
} |
2 |
26 Feb 07 |
jari |
448 |
return; |
2 |
26 Feb 07 |
jari |
449 |
} |
2 |
26 Feb 07 |
jari |
450 |
Object[][] sortedData = new Object[fValuesTable.getRowCount()][fValuesTable.getColumnCount()]; |
2 |
26 Feb 07 |
jari |
451 |
float[] origArray = new float[rows.length]; |
2 |
26 Feb 07 |
jari |
452 |
SortableField[] sortFields = new SortableField[rows.length]; |
2 |
26 Feb 07 |
jari |
453 |
if (column < fieldNames.length) { |
2 |
26 Feb 07 |
jari |
//SortableField[] sortFields = new SortableField[rows.length]; |
2 |
26 Feb 07 |
jari |
455 |
for (int i = 0; i < sortFields.length; i++) { |
2 |
26 Feb 07 |
jari |
456 |
sortFields[i] = new SortableField(i, column); |
2 |
26 Feb 07 |
jari |
//Arrays.sort(sortFields); |
2 |
26 Feb 07 |
jari |
458 |
} |
2 |
26 Feb 07 |
jari |
459 |
Arrays.sort(sortFields); |
2 |
26 Feb 07 |
jari |
//return; |
2 |
26 Feb 07 |
jari |
461 |
} else if (column == univCnt3) { |
2 |
26 Feb 07 |
jari |
462 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
463 |
origArray[i] = ((Float)(fValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
464 |
} |
2 |
26 Feb 07 |
jari |
465 |
} else if (column == univCnt3 + 1) { |
2 |
26 Feb 07 |
jari |
466 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
467 |
origArray[i] = ((Float)(ssGroups.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
468 |
} |
2 |
26 Feb 07 |
jari |
469 |
} else if (column == univCnt3 + 2) { |
2 |
26 Feb 07 |
jari |
470 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
471 |
origArray[i] = ((Float)(ssError.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
472 |
} |
2 |
26 Feb 07 |
jari |
473 |
} else if (column == univCnt3 + 3) { |
2 |
26 Feb 07 |
jari |
474 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
475 |
origArray[i] = ((Float)(dfNumValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
476 |
} |
2 |
26 Feb 07 |
jari |
477 |
} else if (column == univCnt3 + 4) { |
2 |
26 Feb 07 |
jari |
478 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
479 |
origArray[i] = ((Float)(dfDenomValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
480 |
} |
2 |
26 Feb 07 |
jari |
481 |
} else if (column == univCnt3 + 5) { |
2 |
26 Feb 07 |
jari |
482 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
483 |
origArray[i] = ((Float)(pValues.get(rows[i]))).floatValue(); |
2 |
26 Feb 07 |
jari |
484 |
} |
2 |
26 Feb 07 |
jari |
485 |
} else { |
2 |
26 Feb 07 |
jari |
486 |
int currentIndex = column - fieldNames.length; |
2 |
26 Feb 07 |
jari |
487 |
int newIndex = 0; |
2 |
26 Feb 07 |
jari |
488 |
if ((int)(currentIndex%2) == 0) { |
2 |
26 Feb 07 |
jari |
489 |
newIndex = (int)(currentIndex/2); |
2 |
26 Feb 07 |
jari |
490 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
491 |
origArray[i] = geneGroupMeans[rows[i]][newIndex]; |
2 |
26 Feb 07 |
jari |
492 |
} |
2 |
26 Feb 07 |
jari |
493 |
} else { |
2 |
26 Feb 07 |
jari |
494 |
newIndex = (int)((currentIndex - 1)/2); |
2 |
26 Feb 07 |
jari |
495 |
for (int i = 0; i < origArray.length; i++) { |
2 |
26 Feb 07 |
jari |
496 |
origArray[i] = geneGroupSDs[rows[i]][newIndex]; |
2 |
26 Feb 07 |
jari |
497 |
} |
2 |
26 Feb 07 |
jari |
498 |
} |
2 |
26 Feb 07 |
jari |
499 |
} |
2 |
26 Feb 07 |
jari |
500 |
|
2 |
26 Feb 07 |
jari |
501 |
int[] sortedIndices = new int[rows.length]; |
2 |
26 Feb 07 |
jari |
502 |
if (column >= fieldNames.length) { |
2 |
26 Feb 07 |
jari |
503 |
QSort sortArray = new QSort(origArray); |
2 |
26 Feb 07 |
jari |
504 |
sortedIndices = sortArray.getOrigIndx(); |
2 |
26 Feb 07 |
jari |
505 |
} else { |
2 |
26 Feb 07 |
jari |
506 |
for (int i = 0; i < sortedIndices.length; i++) { |
2 |
26 Feb 07 |
jari |
507 |
sortedIndices[i] = sortFields[i].getIndex(); |
2 |
26 Feb 07 |
jari |
508 |
} |
2 |
26 Feb 07 |
jari |
509 |
} |
2 |
26 Feb 07 |
jari |
510 |
if (!ascending) { |
2 |
26 Feb 07 |
jari |
511 |
sortedIndices = reverse(sortedIndices); |
2 |
26 Feb 07 |
jari |
512 |
} |
2 |
26 Feb 07 |
jari |
//sortedIndices = sortNaNs(sortedIndices); //QSort does not appear to handle NaN's well, they show up in the middle of the sorted array |
2 |
26 Feb 07 |
jari |
514 |
for (int i = 0; i < sortedData.length; i++) { |
2 |
26 Feb 07 |
jari |
515 |
for (int j = 0; j < sortedData[i].length; j++) { |
2 |
26 Feb 07 |
jari |
//sortedData[i][j] = tModel.getValueAt(sortedMeansAIndices[i], j); |
2 |
26 Feb 07 |
jari |
517 |
sortedData[i][j] = origData[sortedIndices[i]][j]; |
2 |
26 Feb 07 |
jari |
518 |
} |
2 |
26 Feb 07 |
jari |
519 |
} |
2 |
26 Feb 07 |
jari |
520 |
|
2 |
26 Feb 07 |
jari |
521 |
for (int i = 0; i < sortedData.length; i++) { |
2 |
26 Feb 07 |
jari |
522 |
for (int j = 0; j < sortedData[i].length; j++) { |
2 |
26 Feb 07 |
jari |
523 |
fModel.setValueAt(sortedData[i][j], i, j); |
2 |
26 Feb 07 |
jari |
524 |
} |
2 |
26 Feb 07 |
jari |
525 |
} |
2 |
26 Feb 07 |
jari |
526 |
} |
2 |
26 Feb 07 |
jari |
527 |
|
2 |
26 Feb 07 |
jari |
528 |
private int[] reverse(int[] arr) { |
2 |
26 Feb 07 |
jari |
529 |
int[] revArr = new int[arr.length]; |
2 |
26 Feb 07 |
jari |
530 |
int revCount = 0; |
2 |
26 Feb 07 |
jari |
531 |
int count = arr.length - 1; |
2 |
26 Feb 07 |
jari |
532 |
for (int i=0; i < arr.length; i++) { |
2 |
26 Feb 07 |
jari |
533 |
revArr[revCount] = arr[count]; |
2 |
26 Feb 07 |
jari |
534 |
revCount++; |
2 |
26 Feb 07 |
jari |
535 |
count--; |
2 |
26 Feb 07 |
jari |
536 |
} |
2 |
26 Feb 07 |
jari |
537 |
return revArr; |
2 |
26 Feb 07 |
jari |
538 |
} |
2 |
26 Feb 07 |
jari |
539 |
|
2 |
26 Feb 07 |
jari |
540 |
private class SortableField implements Comparable { |
2 |
26 Feb 07 |
jari |
541 |
private String field; |
2 |
26 Feb 07 |
jari |
542 |
private int index; |
2 |
26 Feb 07 |
jari |
543 |
|
2 |
26 Feb 07 |
jari |
544 |
SortableField(int index, int column) { |
2 |
26 Feb 07 |
jari |
545 |
this.index = index; |
2 |
26 Feb 07 |
jari |
546 |
this.field = (String)(origData[index][column]); |
2 |
26 Feb 07 |
jari |
//System.out.println("SortableField[" + index + "][" + column + "]: index = " + index + ", field = " + field); |
2 |
26 Feb 07 |
jari |
548 |
} |
2 |
26 Feb 07 |
jari |
549 |
|
2 |
26 Feb 07 |
jari |
550 |
public int compareTo(Object other) { |
2 |
26 Feb 07 |
jari |
551 |
SortableField otherField = (SortableField)other; |
2 |
26 Feb 07 |
jari |
552 |
return this.field.compareTo(otherField.getField()); |
2 |
26 Feb 07 |
jari |
553 |
} |
2 |
26 Feb 07 |
jari |
554 |
|
2 |
26 Feb 07 |
jari |
555 |
public int getIndex() { |
2 |
26 Feb 07 |
jari |
556 |
return this.index; |
2 |
26 Feb 07 |
jari |
557 |
} |
2 |
26 Feb 07 |
jari |
558 |
public String getField() { |
2 |
26 Feb 07 |
jari |
559 |
return this.field; |
2 |
26 Feb 07 |
jari |
560 |
} |
2 |
26 Feb 07 |
jari |
561 |
} |
2 |
26 Feb 07 |
jari |
562 |
} |