Personal tools

Cytoscape test2: Difference between revisions

From FANTOM5_SSTAR

Jump to: navigation, search
No edit summary
No edit summary
Line 37: Line 37:
var t;
var t;
var selected = false;
var selected = false;
function sliderTrack() {
z_min = $('#slider1').noUiSlider('getValue', {point: 'lower'});
z_max = $('#slider1').noUiSlider('getValue', {point: 'upper'});
z_min = Math.round(z_min*100)/100;
z_max = Math.round(z_max*100)/100;
$("#cyto_zscore_filter_min").val(z_min);
$("#cyto_zscore_filter_max").val(z_max);
//clearTimeout(t);
//t = setTimeout("setScoreFilter()", 100);
}
function sliderChange() {
sliderTrack();
setScoreFilter();
}
function setScoreFilter() {
vis.filter("edges", function(edge) {
return ((edge.data.zscore >= z_min)&&(edge.data.zscore <= z_max));
}, true);
}
function graphClick(event) {
function graphClick(event) {
Line 101: Line 76:
//}
//}
}
}
function layoutChange() {
vis.layout($("#cyto_layout").val());
}
$("#cyto_layout").change(function(){
layoutChange();
return false;
});
$("#cyto_recalc").click(function(){
layoutChange();
return false;
});
// id of Cytoscape Web container div
// id of Cytoscape Web container div
Line 194: Line 155:
.addListener("select", "", graphSelect)
.addListener("select", "", graphSelect)
.addListener("deselect", "", graphSelect);
.addListener("deselect", "", graphSelect);
var edges = vis.edges();
for (var i in edges) {
var data = edges[i].data;
if (z_max < data.zscore) { z_max = data.zscore; }
}
z_max = Math.ceil(z_max);
z_min = Math.floor(z_min);
$(".sliderbar").noUiSlider("init", { scale: [z_min, z_max], startMin: z_min, startMax: z_max, tracker: sliderTrack, change: sliderChange });
$("#cyto_zscore_filter_min").val(z_min);
$("#cyto_zscore_filter_max").val(z_max);
$("#cyto_zscore_min").html(z_min);
$("#cyto_zscore_max").html(z_max);
graphSelect();  // Empty
});
});

Revision as of 14:10, 25 April 2012

FF:10563-108A5

Cytoscape Web will replace the contents of this div with your graph.

TF to TF network. Motif is an attribute of the source TF node. Promoter is an attribute of the TF to TF edge.