Changeset 531
- Timestamp:
- Jan 10, 2008, 6:18:12 PM (13 years ago)
- Location:
- branches/uk_ac_ebi_Tab2MageImporter
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/uk_ac_ebi_Tab2MageImporter/jsp/uk/ac/ebi/nugo/plugins/experiment.jsp
r530 r531 4 4 <%@ page import="java.util.*"%> 5 5 6 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope=" session"/>6 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope="application"/> 7 7 <!-- submits the form data back to the bean assuming that each form element is matched to a variable in the bean by the same name --> 8 8 <jsp:setProperty name="inputDataBean" property="*"/> … … 32 32 <link rel="stylesheet" type="text/css" href="/base/include/styles/main.css"> 33 33 <link rel="stylesheet" type="text/css" href="/base/include/styles/size_m.css"> 34 35 <script> 36 self.resizeTo(800,850); 37 </script> 34 38 35 39 <script language="JavaScript" src="<%= request.getContextPath()%>/include/scripts/main.js" type="text/javascript"></script> -
branches/uk_ac_ebi_Tab2MageImporter/jsp/uk/ac/ebi/nugo/plugins/hybridizations.jsp
r530 r531 4 4 <%@ page import="java.util.*"%> 5 5 6 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope=" session" />6 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope="application" /> 7 7 <!-- submits the form data back to the bean assuming that each form element is matched to a variable in the bean by the same name --> 8 8 <jsp:setProperty name="inputDataBean" property="*" /> … … 182 182 </tr> 183 183 184 <!-- question 8a --> 185 <tr> 186 <td class="boldText">Subject (replicate) labels:</td> 187 <td class="input"><textarea rows="8" cols="32" name="subjectNames">plant1</textarea></td> 188 <td>Please provide a list of labels(names) for the experimental subjects, one per line, 189 in no particular order (copy and paste from Excel works).</td> 190 </tr> 191 184 192 <!-- question 9 --> 185 193 <tr> 186 194 <td class="boldText">Target tissues:</td> 187 <td class="input"><textarea rows="2" cols="32" name="tissues">stem</textarea></td> 188 <td>List all target tissues (as a comma separated list).<br> 189 Example: liver,heart</td> 195 <td class="input"><textarea rows="4" cols="32" name="tissues">stem</textarea></td> 196 <td>List all target tissues one per line, in no particular order (copy and paste from Excel works).</td> 190 197 </tr> 191 198 -
branches/uk_ac_ebi_Tab2MageImporter/jsp/uk/ac/ebi/nugo/plugins/mappings.jsp
r530 r531 7 7 <%@ page import="uk.ac.ebi.nugo.plugins.*"%> 8 8 9 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope=" session" />9 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope="application" /> 10 10 <!-- submits the form data back to the bean assuming that each form element is matched to a variable in the bean by the same name --> 11 11 <jsp:setProperty name="inputDataBean" property="*" /> … … 51 51 function gatherValues() 52 52 { 53 var fileString = ''; 53 var fileList = ''; 54 var subjectList = ''; 55 var tissueList = ''; 54 56 var frm = document.forms['mappings']; 55 57 var numElements = frm.elements.length; 56 //document.write(numElements);57 //document.write("<br />");58 58 for(var i = 0; i < numElements; i++) 59 59 { 60 60 var value = frm.elements[i].value; 61 61 var id = frm.elements[i].id; 62 63 if(id.match("fileinput")) 62 if(id.match("fileInput")) 64 63 { 65 //document.write("id = " + id); 66 //document.write("<br />"); 67 //document.write("value = " + value); 68 //document.write("<br />"); 69 fileString += frm.elements[i].value + '\t'; 70 } 71 } 72 //document.write('combined output = ' + fileString); 73 frm.fileStringParam.value = fileString; 74 //document.write('value of hidden input = ' + frm.fileStringParam.value); 64 fileList += frm.elements[i].value + '\t'; 65 } 66 if(id.match("subjectInput")) 67 { 68 subjectList += frm.elements[i].value + '\t'; 69 } 70 if(id.match("tissueInput")) 71 { 72 tissueList += frm.elements[i].value + '\t'; 73 } 74 } 75 frm.fileList.value = fileList; 76 frm.subjectList.value = subjectList; 77 frm.tissueList.value = tissueList; 75 78 } 76 79 … … 88 91 <input type="hidden" name="cmd" value="SetParameters"> 89 92 <input type="hidden" name="requestId" value="<%=requestId%>"> 90 <input type="hidden" id="fileStringParam" name="parameter:fileStringParam" value""/> 93 <input type="hidden" id="fileList" name="parameter:fileList" value""/> 94 <input type="hidden" id="subjectList" name="parameter:subjectList" value""/> 95 <input type="hidden" id="tissueList" name="parameter:tissueList" value""/> 91 96 92 97 <!-- these are the parameters from the previous input pages; need to pick them up individually from the bean here; ugly as hell but can't be done any other way --> … … 135 140 <input type="hidden" name="parameter:pooling" value="<%=inputDataBean.getPooling()%>"> 136 141 <input type="hidden" name="parameter:zipFile" value="<%=request.getParameter("path") %>" id="zipFile"> 142 <input type="hidden" name="parameter:subjectNames" value="<%=inputDataBean.getSubjectNames()%>"> 143 137 144 138 145 <% … … 194 201 195 202 dc.close(); 203 204 //next get the subjectNames and make up select boxes with these 205 //they too have to be mapped to filenames 206 String [] subjectNames = request.getParameter("subjectNames").split("\n"); 207 208 //we also need to parse out the tissues string to produce another column of select boxes 209 String [] tissueNames = request.getParameter("tissues").split("\n"); 196 210 %> 197 211 … … 201 215 202 216 The table below holds a list of all possible factor value combinations used in your experiment. 203 Please select, for each combination, the appropriate file name from the drop down menu.</p><p>217 Please select, for each combination, the appropriate file, subject and tissue from the drop down menu.</p><p> 204 218 205 219 <!-- this table holds the combinations of factor values --> … … 213 227 <!-- file selector header --> 214 228 <td class="header"><h3>File</h3></td> 229 <td class="header"><h3>Subject</h3></td> 230 <td class="header"><h3>Tissue</h3></td> 215 231 216 232 <!-- factor names --> … … 236 252 <!-- first we need a cell with a drop down menu where we can select a filename to match the combination of factor values--> 237 253 238 <td class="input" ><select id="file input<%=i %>">254 <td class="input" ><select id="fileInput<%=i %>"> 239 255 <% 240 256 for (int k = 0; k < fileNamesArr.length; k++) … … 243 259 244 260 <option><%=fileNamesArr[k]%></option> 261 262 <% 263 } 264 %> 265 </select></td> 266 267 <!-- next we need a cell with a drop down menu where we can select a subject name to match the combination of factor values--> 268 269 <td class="input" ><select id="subjectInput<%=i %>"> 270 <% 271 for (int k = 0; k < subjectNames.length; k++) 272 { 273 %> 274 275 <option><%=subjectNames[k]%></option> 276 277 <% 278 } 279 %> 280 </select></td> 281 282 <!-- next we need a cell with a drop down menu where we can select a tissue name to match the combination of factor values--> 283 284 <td class="input" ><select id="tissueInput<%=i %>"> 285 <% 286 for (int k = 0; k < tissueNames.length; k++) 287 { 288 %> 289 290 <option><%=tissueNames[k]%></option> 245 291 246 292 <% -
branches/uk_ac_ebi_Tab2MageImporter/jsp/uk/ac/ebi/nugo/plugins/protocols.jsp
r530 r531 5 5 <%@ page import="java.lang.*"%> 6 6 7 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope=" session" />7 <jsp:useBean id="inputDataBean" class="uk.ac.ebi.nugo.plugins.DataBean" scope="application" /> 8 8 <!-- submits the form data back to the bean assuming that each form element is matched to a variable in the bean by the same name --> 9 9 <jsp:setProperty name="inputDataBean" property="*" /> -
branches/uk_ac_ebi_Tab2MageImporter/src/uk/ac/ebi/nugo/plugins/DataBean.java
r517 r531 44 44 String zipFile; 45 45 String experimentId; 46 String subjectNames; 46 47 47 48 … … 365 366 { 366 367 this.numTreatmentGroups = numTreatmentGroups; 368 } 369 public String getSubjectNames() 370 { 371 return subjectNames; 372 } 373 public void setSubjectNames(String subjectNames) 374 { 375 this.subjectNames = subjectNames; 367 376 } 368 377 -
branches/uk_ac_ebi_Tab2MageImporter/src/uk/ac/ebi/nugo/plugins/Tab2MageImporter.java
r530 r531 113 113 "hybridizationProtocolParams","scanningProtocolParams","platform","organism", 114 114 "numDesigns","dyeSwap","refSample","numTreatmentGroups","expFactors","numReplicates", 115 "tissues","pooling","zipFile", "file StringParam"};115 "tissues","pooling","zipFile", "fileList", "subjectList", "tissueList"}; 116 116 117 117 -
branches/uk_ac_ebi_Tab2MageImporter/src/uk/ac/ebi/nugo/plugins/Tab2MageWriter.java
r530 r531 29 29 String[] factorNames; 30 30 String [] fileNames; 31 32 String domain; 33 String accession; 34 String qualityControl; 35 String experimentalDesign; 36 String experimentName; 37 String description; 38 String releaseDate; 39 String submissionDate; 40 String submitter; 41 String organization; 42 String publicationTitle; 43 String authors; 44 String journal; 45 String volume; 46 String issue; 47 String pages; 48 String year; 49 String pubmedId; 50 String treatmentProtocol; 51 String extractionProtocol; 52 String labelingProtocol; 53 String hybridizationProtocol; 54 String scanningProtocol; 55 String treatmentProtocolParams; 56 String extractionProtocolParams; 57 String labelingProtocolParams; 58 String hybridizationProtocolParams; 59 String scanningProtocolParams; 60 String platform; 61 String organism; 62 String numDesigns; 63 String dyeSwap; 64 String refSample; 65 String numTreatmentGroups; 66 String expFactors; 67 String numReplicates; 68 String tissues; 69 String pooling; 70 String zipFile; 71 String experimentId; 72 String fileStringParam; 73 31 String [] subjectNames; 32 String [] tissueNames; 33 34 public String domain; 35 public String accession; 36 public String qualityControl; 37 public String experimentalDesign; 38 public String experimentName; 39 public String description; 40 public String releaseDate; 41 public String submissionDate; 42 public String submitter; 43 public String organization; 44 public String publicationTitle; 45 public String authors; 46 public String journal; 47 public String volume; 48 public String issue; 49 public String pages; 50 public String year; 51 public String pubmedId; 52 public String treatmentProtocol; 53 public String extractionProtocol; 54 public String labelingProtocol; 55 public String hybridizationProtocol; 56 public String scanningProtocol; 57 public String treatmentProtocolParams; 58 public String extractionProtocolParams; 59 public String labelingProtocolParams; 60 public String hybridizationProtocolParams; 61 public String scanningProtocolParams; 62 public String platform; 63 public String organism; 64 public String numDesigns; 65 public String dyeSwap; 66 public String refSample; 67 public String numTreatmentGroups; 68 public String expFactors; 69 public String numReplicates; 70 public String tissues; 71 public String pooling; 72 public String zipFile; 73 public String experimentId; 74 public String fileList; 75 public String subjectList; 76 public String tissueList; 77 74 78 75 79 // ===================================================c'tor================================================ … … 87 91 public Tab2MageWriter() 88 92 { 89 initTestParamValues(); 93 90 94 } 91 95 … … 104 108 field.set(this, job.getValue(paramNames[i])); 105 109 } 106 110 107 111 //now extract the factor values and store them suitably so we can access them 108 112 makeFactorValueCombinations(); … … 113 117 } 114 118 } 115 116 // ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 117 118 p rivatevoid makeFactorValueCombinations()119 120 // ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 121 122 public void makeFactorValueCombinations() 119 123 { 120 124 //first extract the factor names and the possible values … … 147 151 System.out.println(); 148 152 } 149 153 150 154 //now we want the filenames in a separate array so we can add them to their appropriate combinations as selected 151 155 //by the user in the UI … … 153 157 //array in the order we find them in the string 154 158 //they then match the order of the combinations in the cartesian product 155 fileNames = fileStringParam.split("\t"); 156 } 157 159 fileNames = fileList.split("\t"); 160 //ditto for the lists of subject names and tissues 161 subjectNames = subjectList.split("\t"); 162 tissueNames = tissueList.split("\t"); 163 } 164 158 165 159 166 // ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- … … 175 182 176 183 String[] rowHeaders = new String[] 177 { "domain", "accession", "quality_control", "experiment_design_type", "name", "description",184 { "domain", "accession", "quality_control", "experiment_design_type", "name", "description", 178 185 "release_date", "submission_date", "submitter", "organization", 179 186 "publication_title", "authors", "journal", "volume", "issue", "pages", 180 187 "year", "pubmed_id" }; 181 188 String[] experimentParams = new String[] 182 { domain, accession, qualityControl, experimentalDesign, experimentName, description, releaseDate,189 { domain, accession, qualityControl, experimentalDesign, experimentName, description, releaseDate, 183 190 submissionDate, submitter, organization, publicationTitle, authors, 184 191 journal, volume, issue, pages, year, pubmedId }; … … 208 215 */ 209 216 String[] accessions = new String[] 210 { "P-DIET-1", "P-EXTR-1", "P-LABL-1", "P-HYBR-1", "P-SCAN-1" };217 { "P-DIET-1", "P-EXTR-1", "P-LABL-1", "P-HYBR-1", "P-SCAN-1" }; 211 218 String[] names = new String[] 212 { "treatment", "extraction", "labeling", "hybridization", "scanning" };219 { "treatment", "extraction", "labeling", "hybridization", "scanning" }; 213 220 String[] values = new String[] 214 { treatmentProtocol, extractionProtocol, labelingProtocol, hybridizationProtocol, scanningProtocol };221 { treatmentProtocol, extractionProtocol, labelingProtocol, hybridizationProtocol, scanningProtocol }; 215 222 String[] parameters = new String[] 216 { treatmentProtocolParams, extractionProtocolParams, labelingProtocolParams,223 { treatmentProtocolParams, extractionProtocolParams, labelingProtocolParams, 217 224 hybridizationProtocolParams, scanningProtocolParams }; 218 225 String[] types = new String[] 219 { "grow", "extraction", "labeling", "hybridization", "scanning" };226 { "grow", "extraction", "labeling", "hybridization", "scanning" }; 220 227 221 228 // print header … … 241 248 // print column headers for the section 242 249 String[] colHeaders = new String[] 243 { "File[raw]", "Array[accession]", "BioSource", "BioMaterialCharacteristics[Organism]",250 { "File[raw]", "Array[accession]", "BioSource", "BioMaterialCharacteristics[Organism]", 244 251 "BioMaterialCharacteristics[OrganismPart]", 245 252 "BioMaterialCharacteristics[CellType]", "Sample", "Protocol[grow]", … … 251 258 t2mContent += colHeaders[i] + "\t"; 252 259 } 253 260 254 261 //now print the factorvalue headers 255 262 for (int i = 0; i < factorNames.length; i++) … … 257 264 t2mContent += "FactorValue["+factorNames[i] + "]\t"; 258 265 } 259 266 260 267 //next line will be data 261 268 t2mContent += "\n"; 262 269 263 //single channel data -- currently only Affy 264 //we only need a single record for each tissue in each subject here 270 //determine whether this is a single or dual channel experiment 271 boolean singleChannel = false; 272 //the number of times we have to print the block of data below 273 //with dual channel platforms we have to print each block (row) twice 274 int numPrintRepeats = 2; 265 275 if (platform.equalsIgnoreCase("affymetrix")) 266 276 { 267 int count = 1; 268 269 int numSubjects = Integer.parseInt(numReplicates); 270 String[] allTissues = tissues.split(","); 271 int numTissues = allTissues.length; 272 int numGroups = Integer.parseInt(numTreatmentGroups); 273 274 // for each treatment group 275 for (int i = 1; i <= numGroups; i++) 277 singleChannel = true; 278 numPrintRepeats = 1; 279 } 280 281 282 //we need a single record for each tissue in each subject here 283 284 int count = 1; 285 286 int numSubjects = Integer.parseInt(numReplicates); 287 String[] allTissues = tissues.split(","); 288 int numTissues = allTissues.length; 289 int numGroups = Integer.parseInt(numTreatmentGroups); 290 291 // for each treatment group i.e. factor value combination 292 for (int i = 1; i <= numGroups; i++) 293 { 294 System.out.println("i=" +i); 295 System.out.println("count = " + count); 296 int subjectCount = 0; 297 // for each subject within each group i.e. biological replicate within each factor value combination 298 for (int j = 1; j <= numSubjects; j++) 276 299 { 277 System.out.println("i=" +i);278 int subjectCount = 0;279 // for each subject within each group280 for (int j = 1; j <= numSubjects; j++)300 subjectCount = (i - 1) * numSubjects + j; 301 System.out.println("subjectCount = "+ subjectCount); 302 // for each target tissue for this subject 303 for (int k = 1; k <= numTissues; k++) 281 304 { 282 subjectCount = (i - 1) * numSubjects + j; 283 // for each target tissue 284 for (int k = 1; k <= numTissues; k++) 305 for(int r = 0; r< numPrintRepeats; r++) 285 306 { 286 307 String subjectName = subjectNames[count-1]; 308 287 309 // file count first 288 310 t2mContent += fileNames[count-1] + "\t" + 311 289 312 // accession no. i.e the array 290 313 // design 291 314 accession + "\t" + 315 292 316 // bio source 293 "group-" + i + "-subject-" + subjectCount + "\t" + 317 subjectName + "\t" + 318 294 319 // BioMaterialCharacteristics[Organism] 295 320 organism + "\t" + 321 296 322 // BioMaterialCharacteristics[OrganismPart] 297 allTissues[k - 1] + "\t" + 323 tissueNames[count-1] + "\t" + 324 298 325 // BioMaterialCharacteristics[CellType] 299 326 "" + "\t" + 327 300 328 // sample 301 "group-" + i + "-subject-" + subjectCount + ".sample-" + k + "\t" + 329 subjectName + ".sample-" + k + "\t" + 330 302 331 // Protocol[grow] 303 332 "P-DIET-1" + "\t" + 333 304 334 // Extract 305 "group-" + i + "-subject-" + subjectCount + ".sample-" + k + "-extract" + "\t" + 335 subjectName + ".sample-" + k + "-extract" + "\t" + 336 306 337 // Protocol[extraction] 307 338 "P-EXTR-1" + "\t" + 339 308 340 // LabeledExtract 309 "group-" + i + "-subject-" + subjectCount + ".sample-" + k + "-extract-le" + "\t" + 341 subjectName + ".sample-" + k + "-extract-le" + "\t" + 342 310 343 // Protocol[labeling] 311 "P-LABL-1" + "\t" + 344 "P-LABL-1" + "\t" ; 345 312 346 // Dye 313 "biotin" + "\t" + 347 //depends on platform and repeat no. 348 if(singleChannel) 349 { 350 t2mContent +="biotin" + "\t"; 351 } 352 if(!singleChannel && numPrintRepeats==0) 353 { 354 t2mContent +="Cy3" + "\t"; 355 } 356 if(!singleChannel && numPrintRepeats==1) 357 { 358 t2mContent +="Cy5" + "\t"; 359 } 360 314 361 // Hybridization 315 "hybridization-" + count + "\t" + 362 t2mContent += "hybridization-" + count + "\t" + 363 316 364 // Protocol[hybridization] 317 365 "P-HYBR-1" + "\t" + 366 318 367 // Scan 319 368 "scan-" + count + "\t" + 369 320 370 // Protocol[scanning] 321 371 "P-SCAN-1" + "\t"; 322 372 323 373 //now print all the factor values 324 374 // FactorValue[Treatment Type] … … 327 377 for(int n=0; n< cartesianProduct[0].length; n++) 328 378 { 329 System.out.println("count = " + count);330 379 System.out.println("n = "+ n); 331 380 t2mContent +=cartesianProduct[i-1][n]+ "\t"; … … 339 388 } 340 389 } 341 342 else //non Affy data, i.e. two channel343 {344 345 int count = 1;346 347 int numSubjects = Integer.parseInt(numReplicates);348 String[] allTissues = tissues.split(",");349 int numTissues = allTissues.length;350 int numGroups = Integer.parseInt(numTreatmentGroups);351 352 // for each treatment group353 for (int i = 1; i <= numGroups; i++)354 {355 int subjectCount = 0;356 // for each subject within each group357 for (int j = 1; j <= numSubjects; j++)358 {359 subjectCount = (i - 1) * numSubjects + j;360 // for each target tissue361 for (int k = 1; k <= numTissues; k++)362 {363 // this whole first block prints364 // the data for the first365 // channel366 367 // file count first368 t2mContent += fileNames[count-1] + "\t" +369 // accession no. i.e the array370 // design371 accession + "\t" +372 // bio source373 "group-" + i + "-subject-" + subjectCount + "\t" +374 // BioMaterialCharacteristics[Organism]375 organism + "\t" +376 // BioMaterialCharacteristics[OrganismPart]377 allTissues[k - 1] + "\t" +378 // BioMaterialCharacteristics[CellType]379 "" + "\t" +380 // sample381 "group-" + i + "-subject-" + subjectCount + ".sample-" + k + "\t" +382 // Protocol[grow]383 "P-DIET-1" + "\t" +384 // Extract385 "group-" + i + "-subject-" + subjectCount + ".sample-" + k + "-extract" + "\t" +386 // Protocol[extraction]387 "P-EXTR-1" + "\t" +388 // LabeledExtract389 "group-" + i + "-subject-" + subjectCount + ".sample-" + k + "-extract-le" + "\t" +390 // Protocol[labeling]391 "P-LABL-1" + "\t" +392 // Dye393 "Cy3" + "\t" +394 // Hybridization395 "hybridization-" + count + "\t" +396 // Protocol[hybridization]397 "P-HYBR-1" + "\t" +398 // Scan399 "scan-" + count + "\t" +400 // Protocol[scanning]401 "P-SCAN-1" + "\t" +402 // FactorValue[Treatment Type]403 "trt_group" + i + "\t";404 405 // new line406 t2mContent += "\n";407 408 // the second block prints the409 // data for the second channel410 411 // file count first412 t2mContent += fileNames[count-1] + "\t" +413 // accession no. i.e the array414 // design415 accession + "\t" +416 // bio source417 "reference" + "\t" +418 // BioMaterialCharacteristics[Organism]419 organism + "\t" +420 // BioMaterialCharacteristics[OrganismPart]421 "multi-tissue" + "\t" +422 // BioMaterialCharacteristics[CellType]423 "multi-cell type" + "\t" +424 // sample425 "reference" + "\t" +426 // Protocol[grow]427 "P-DIET-1" + "\t" +428 // Extract429 "reference" + "\t" +430 // Protocol[extraction]431 "P-EXTR-1" + "\t" +432 // LabeledExtract433 "reference" + "\t" +434 // Protocol[labeling]435 "P-LABL-1" + "\t" +436 // Dye437 "Cy5" + "\t" +438 // Hybridization439 "h" + count + "\t" +440 // Protocol[hybridization]441 "P-HYBR-1" + "\t" +442 // Scan443 "scan-" + count + "\t" +444 // Protocol[scanning]445 "P-SCAN-1" + "\t" +446 // FactorValue[Treatment Type]447 "reference" + "\t";448 449 // new line450 t2mContent += "\n";451 452 count++;453 }454 }455 }456 }457 458 // //////////////////////////////////////////////////////////////////////////////////////////////////////////459 460 390 } 461 391 … … 468 398 { 469 399 // set up a file writer 470 400 dc = sc.newDbControl(); 471 401 net.sf.basedb.core.File t2mFile = net.sf.basedb.core.File.getNew(dc, dir); 472 402 System.out.println("dir for writing new tab2mage file = " + dir.getName()); … … 543 473 // ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- 544 474 545 private void initTestParamValues()546 {547 /*548 * --org Homo_sapiens --array Agilent1 --single 2 --ref yes549 * --dye no --trtgroup 6 --factors550 * compound(aspirin,ibuprofen);dose(none,medium,high) --target551 * liver,heart,brain --subject 4552 */553 554 // experiment section555 experimentId = "2";556 domain = "scri.ac.uk";557 accession = "Affymetrix1";558 qualityControl = "biological replicate,spike quality control";559 experimentalDesign = "cell_component_comparison_design,RNA_stability_design,family_history_design,";560 experimentName = "New experiment";561 description = "description goes here";562 releaseDate = "2007-12-03";563 submissionDate = "2007-12-03";564 submitter = "Joe Bloggs";565 organization = "SCRI";566 publicationTitle = "My Ropey Paper";567 authors = "Bloggs, Joe";568 journal = "The Journal of Irreproducible Results";569 volume = "5";570 issue = "2";571 pages = "1234-1235";572 year = "2007";573 pubmedId = "11009762";574 575 // protocols576 treatmentProtocol = "my treatment protocol text";577 extractionProtocol = " my extraction protocol text";578 labelingProtocol = " my labeling protocol text";579 hybridizationProtocol = "my hybs protocol text";580 scanningProtocol = " my scanning protocol text";581 treatmentProtocolParams = "param1";582 extractionProtocolParams = "param2";583 labelingProtocolParams = "param3";584 hybridizationProtocolParams = "param4";585 scanningProtocolParams = " param5";586 587 // hybs588 platform = "Affymetrix";589 organism = "Solanum tuberosum";590 numDesigns = "1";591 dyeSwap = "no";592 refSample = "yes";593 numTreatmentGroups = "4";594 expFactors = "Strain(mutant,wildtype)\nTreatment(treated,control)";595 numReplicates = "2";596 tissues = "stem";597 pooling = "no";598 zipFile = "/home/michab/potato_small.zip";599 fileStringParam = "file1.CEL\tfile2.CEL\tfile3.CEL\tfile4.CEL\tfile5.CEL\tfile6.CEL\tfile7.CEL\tfile8.CEL";600 601 602 //now extract the factor values and store them suitably so we can access them603 makeFactorValueCombinations();604 605 }606 // -----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------607 475 }// end class -
branches/uk_ac_ebi_Tab2MageImporter/src/uk/ac/ebi/nugo/plugins/Tab2MageWriterTest.java
r526 r531 17 17 //get the tab2mage output gerenated by the writer 18 18 Tab2MageWriter writer = new Tab2MageWriter(); 19 20 //set parameters for testing 21 writer.experimentId = "2"; 22 writer.domain = "scri.ac.uk"; 23 writer.accession = "Affymetrix1"; 24 writer.qualityControl = "biological replicate,spike quality control"; 25 writer.experimentalDesign = "cell_component_comparison_design,RNA_stability_design,family_history_design,"; 26 writer.experimentName = "New experiment"; 27 writer.description = "description goes here"; 28 writer.releaseDate = "2007-12-03"; 29 writer.submissionDate = "2007-12-03"; 30 writer.submitter = "Joe Bloggs"; 31 writer.organization = "SCRI"; 32 writer.publicationTitle = "My Ropey Paper"; 33 writer.authors = "Bloggs, Joe"; 34 writer.journal = "The Journal of Irreproducible Results"; 35 writer.volume = "5"; 36 writer.issue = "2"; 37 writer.pages = "1234-1235"; 38 writer.year = "2007"; 39 writer.pubmedId = "11009762"; 40 41 // protocols 42 writer.treatmentProtocol = "my treatment protocol text"; 43 writer.extractionProtocol = " my extraction protocol text"; 44 writer.labelingProtocol = " my labeling protocol text"; 45 writer.hybridizationProtocol = "my hybs protocol text"; 46 writer.scanningProtocol = " my scanning protocol text"; 47 writer.treatmentProtocolParams = "param1"; 48 writer.extractionProtocolParams = "param2"; 49 writer.labelingProtocolParams = "param3"; 50 writer.hybridizationProtocolParams = "param4"; 51 writer.scanningProtocolParams = " param5"; 52 53 // hybs 54 writer.platform = "Genepix"; 55 writer.organism = "Solanum tuberosum"; 56 writer.numDesigns = "1"; 57 writer.dyeSwap = "no"; 58 writer.refSample = "yes"; 59 writer.numTreatmentGroups = "4"; 60 writer.expFactors = "Strain(mutant,wildtype)\nTreatment(treated,control)"; 61 writer.numReplicates = "2"; 62 writer.tissues = "stem"; 63 writer.pooling = "no"; 64 writer.zipFile = "/home/michab/potato_small.zip"; 65 writer.fileList = "file1.CEL\tfile2.CEL\tfile3.CEL\tfile4.CEL\tfile5.CEL\tfile6.CEL\tfile7.CEL\tfile8.CEL"; 66 writer.subjectList = "plant1\tplant2\tplant3\tplant4\tplant5\tplant6\tplant7\tplant8"; 67 writer.tissueList = "stem\tleaf\troot\tstem\tleaf\troot\tstem\tleaf"; 68 69 writer.makeFactorValueCombinations(); 70 71 19 72 String t2mContent = writer.generateFileContents(); 20 73 System.out.println("t2mContent = \n\n" + t2mContent);
Note: See TracChangeset
for help on using the changeset viewer.