Texts can be aligned with the attributes ''anchorX'' and ''anchorY''. Possible values for ''anchorX'' are 'left', 'middle', right'. Possible values for ''anchorY'' are 'bottom', 'middle', 'top'. Text can be rotated if it is declared as ''display:"internal"''. For SVG this means, instead of an HTML div the SVG text is taken as text node.



Here, at construction time each point receives a function pair as coordinates. In each update these functions which return Math.random() are called. Thus in each update each point receives new random coordinates. The 50 points are updated on the onmousemove event.

This can be used to calculate π & `pi` using statistics. After each update we count the number of points inside the circle (with midpoint [0,0] and radius 1) and outside the circle. The points are restricted to the square with midpoint [0,0] and edges of length 2.

Please, move the mouse pointer over this area: