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

Datum

parent 499f702f
No related branches found
No related tags found
1 merge request!24Main
......@@ -325,10 +325,11 @@ function textbox_content(node) {
text_info = "Title:" + '</br>' + node.name +
'</br>' +'</br>'+"Author:"+ '</br>' +authors+'</br>'+'</br>'+"Date:"+'</br>'
+node.year+'</br>'+'</br>'+"Journal:"+'</br>'+node.journal+'</br>'+'</br>'+"DOI:"
+'</br>'+'<a href="'+node.doi+ '">'+node.doi+'</a>'+'</br>'+'</br>'+"Citations:"
+'</br>'+node.doi+'</br>'+'</br>'+"Citations:"
+'</br>'+node.citations;
text_abstract = node.abstract;
document.getElementById('textbox').innerHTML = text_info;
document.getElementById('textbox').innerHTML = text_info;
}
/**
......
......@@ -121,7 +121,7 @@ var simulation = d3.forceSimulation()
else {return 75;}
}).strength(1))
.force("charge", d3.forceManyBody().strength(0.001))
.force("center", d3.forceCenter(width/2-20, height/2+20))
.force("center", d3.forceCenter(width/2-20, height/2+40))
.alpha(0.004)
.velocityDecay(0.65)
.on("end", zoom_to);
......@@ -205,7 +205,7 @@ function update(links, nodes) {
function updateXAxis(nodes) {
years = [];
for (i = 0; i < nodes.length; i++) {
years.push(parseInt((nodes[i]["year"]).split(" ")[2]));
years.push(parseInt(parseInt(/\d{4}\s*$/.exec(nodes[i]["year"]))));
}
xscale = d3.scaleLinear()
......@@ -413,11 +413,11 @@ function display_abstract(a) {
* updates the positions of the links and nodes
*/
function handle_tick() {
link.attr("x1", function (d) {return xscale(parseInt((d.source.year).split(" ")[2]));})
link.attr("x1", function (d) {return xscale(parseInt(/\d{4}\s*$/.exec(d.source.year)));})
.attr("y1", function (d) {return d.source.y;})
.attr("x2", function (d) {return xscale(parseInt((d.target.year).split(" ")[2]));})
.attr("x2", function (d) {return xscale(parseInt(/\d{4}\s*$/.exec(d.target.year)));})
.attr("y2", function (d) {return d.target.y;});
node.attr("transform", function (d) {return "translate(" + xscale(parseInt((d.year).split(" ")[2])) + ", " + d.y + ")";});
node.attr("transform", function (d) {return "translate(" + xscale(parseInt(/\d{4}\s*$/.exec(d.year))) + ", " + d.y + ")";});
}
/**
......
This diff is collapsed.
File mode changed from 100755 to 100644
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment