From 8422175f0a82e03e1b7fd9ef41da321f54dc0598 Mon Sep 17 00:00:00 2001 From: Pitchaya Boonsarngsuk <2285135b@student.gla.ac.uk> Date: Wed, 31 Jan 2018 15:52:15 +0000 Subject: [PATCH] Add comments 2 --- .../src/neighbourSampling-papaparsing/linkForce.js | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/examples/js/src/neighbourSampling-papaparsing/linkForce.js b/examples/js/src/neighbourSampling-papaparsing/linkForce.js index 56a039a..0143b49 100644 --- a/examples/js/src/neighbourSampling-papaparsing/linkForce.js +++ b/examples/js/src/neighbourSampling-papaparsing/linkForce.js @@ -33,16 +33,17 @@ function startLinkSimulation() { } /* Add force - * Please add the distance function before feeding the force - * it to the simulation or adding links. + * Please add the distance function, links, and set simulation nodes + * before feeding the force to the simulation. * - * On setting the distance fn and being initialized by the simulation, the + * On setting the distance fn or being initialized by the simulation, the * force will pre-calculate high-dimensional distances of every link and * store that as cache. - * Adding distance fn before links means that the first pre-calculation will - * calculate noting as there was no link. + * Adding distance fn and links before being initialize by the simulation + * means that the first pre-calculation will calculate noting as there was + * no nodes list. * The full pre-calculation will then occur once when the force is being - * initialized by the simulation. + * initialized by the simulation where nodes list is given. */ simulation