Skip to content
Snippets Groups Projects
Commit 6594b1a7 authored by Stahl, Merle's avatar Stahl, Merle
Browse files

aufgeräumt

parent 72365b3b
No related branches found
No related tags found
2 merge requests!10Output,!9Main
This commit is part of merge request !9. Comments created here will be created in the context of that merge request.
...@@ -35,7 +35,7 @@ Starting a python web server: ...@@ -35,7 +35,7 @@ Starting a python web server:
Access to the server: Access to the server:
[http://0.0.0.0/:\<port\>](http://0.0.0.0/:<port>) [http://0.0.0.0/:\<port\>](http://0.0.0.0/:<port>)
## Files in directory ## Files in Directory
- **index.html**: webpage - **index.html**: webpage
- **cn.js**: javascript code for force-directed graph, text elements and legend - **cn.js**: javascript code for force-directed graph, text elements and legend
- **json_text.json**: example data - **json_text.json**: example data
......
...@@ -25,7 +25,7 @@ y_scale = d3.scaleOrdinal() ...@@ -25,7 +25,7 @@ y_scale = d3.scaleOrdinal()
to_remove; to_remove;
/** /**
* creates node object and default radius * creates node object and (default) radius
*/ */
var node, var node,
r = 10; r = 10;
...@@ -36,8 +36,7 @@ r = 10; ...@@ -36,8 +36,7 @@ r = 10;
var link; var link;
/** /**
* creates a background * creates a background with a click functionality
* creates a click functionality of the background
*/ */
var rect = svg.append("rect") var rect = svg.append("rect")
.attr("x", 0) .attr("x", 0)
...@@ -143,7 +142,7 @@ d3.json("json_text.json").then(function(graph) { ...@@ -143,7 +142,7 @@ d3.json("json_text.json").then(function(graph) {
/** /**
* calls update functions for links and nodes * calls update functions for links and nodes
* adds the nodes, links and tick functionailty to the simulation * adds the nodes, links and tick functionality to the simulation
* @param {object} nodes - nodes * @param {object} nodes - nodes
* @param {object} links - links * @param {object} links - links
*/ */
...@@ -177,9 +176,8 @@ function update_links(links) { ...@@ -177,9 +176,8 @@ function update_links(links) {
} }
/** /**
* initializes and shows nodes with circles and texts * initializes and shows nodes with circles, texts and a click functionality
* creates a new drag behavior and applies it to the circles * creates a new drag behavior and applies it to the circles
* creates a click functionality of the circles and texts
* @param {object} nodes - nodes * @param {object} nodes - nodes
*/ */
function update_nodes(nodes) { function update_nodes(nodes) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment