|
|
Line 685: |
Line 685: |
| function setup(){ | | function setup(){ |
| document.write('test') | | document.write('test') |
- | $('#visualizationButtons').empty() | + | |
- | $('#infovis').empty()
| + | |
- | $('#readout').empty()
| + | |
- | addForbiddenSequences()
| + | |
- | sensors = document.plasmidForm.sensors.value.toLowerCase()
| + | |
- | sensorArray = formatSensors(sensors)
| + | |
- | promoters = formatPartsregistryPromoters()
| + | |
- | sensorArray = promoters.concat(sensorArray)
| + | |
- | tempArray = new Array()
| + | |
- | j = 0
| + | |
- | number = 0
| + | |
- | targetSites = new Array()
| + | |
- | for (sensor in sensorArray){
| + | |
- | tempArray[j] = sensorArray[sensor]
| + | |
- | j++
| + | |
- | if (j%5 === 0 && j !== 0){
| + | |
- | configuratePlasmid(tempArray,number)
| + | |
- | number++
| + | |
- | tempArray = new Array()
| + | |
- | j = 0
| + | |
- | for (item in memoryPlasmid.memoryObjects){
| + | |
- | site = new Object()
| + | |
- | site.zincFingerDescription = memoryPlasmid.memoryObjects[item].zincFinger.featureObject.description
| + | |
- | site.zincFinger = memoryPlasmid.memoryObjects[item].zincFinger.featureObject.target
| + | |
- | site.zincFingerLength = site.zincFinger.length
| + | |
- | site.methyltransferaseDescription = memoryPlasmid.memoryObjects[item].methyltransferase.featureObject.description
| + | |
- | site.methyltransferase = memoryPlasmid.memoryObjects[item].methyltransferase.featureObject.target
| + | |
- | site.methyltransferaseLength = site.methyltransferase.length
| + | |
- | site.sensor = memoryPlasmid.memoryObjects[item].sensor.description
| + | |
- | targetSites.push(site)
| + | |
- | }
| + | |
- | }
| + | |
- | }
| + | |
- | if (j%5 !== 0){
| + | |
- | configuratePlasmid(tempArray,number)
| + | |
- | for (item in memoryPlasmid.memoryObjects){
| + | |
- | site = new Object()
| + | |
- | site.zincFingerDescription = memoryPlasmid.memoryObjects[item].zincFinger.featureObject.description
| + | |
- | site.zincFinger = memoryPlasmid.memoryObjects[item].zincFinger.featureObject.target
| + | |
- | site.zincFingerLength = site.zincFinger.length
| + | |
- | site.methyltransferaseDescription = memoryPlasmid.memoryObjects[item].methyltransferase.featureObject.description
| + | |
- | site.methyltransferase = memoryPlasmid.memoryObjects[item].methyltransferase.featureObject.target
| + | |
- | site.methyltransferaseLength = site.methyltransferase.length
| + | |
- | site.sensor = memoryPlasmid.memoryObjects[item].sensor.description
| + | |
- | targetSites.push(site)
| + | |
- | }
| + | |
- | }
| + | |
- | //genbankRestriction(targetSites)
| + | |
- | json = createJSONRestriction(targetSites)
| + | |
- | $('#visualizationButtons').append('<input type="hidden" name="json-1" value="'+escape(JSON.stringify(json))+'"/><input class="submit" type="submit" value="Restriction Plasmid" onclick="visualization(-1);return false"/>');
| + | |
- | $('#readout').append('<input type="textfield" name="readout" value=""/><input class="submit" type="submit" value="Submit" onClick="getReadout();return false"/>');
| + | |
| } | | } |
| | | |