{
svgObj.selectAll("#dot1").data([1]).join("circle")
.attr("cx", point1.x)
.attr("cy", point1.y)
.attr("r", 5)
.attr("id","dot1");
svgObj.selectAll("#dot2").data([1]).join("circle")
.attr("cx", point2.x)
.attr("cy", point2.y)
.attr("r", 5)
.attr("id","dot2");
svgObj.selectAll(".datadot")
.data(data)
.join("circle")
.attr("cx", d => curve2.node().getPointAtLength(d).x)
.attr("cy", d => curve2.node().getPointAtLength(d).y)
.attr("r", 5)
.classed("datadot", true);
}