Thanks a lot for this nice and clean solution. It’s fantastic. Now it is very
easy to make scatter plots from the output of c++ libraries and other kind of
applications: two axes and a path build like this
path curve;
numeric i; i:=1;
curve := my_offset(i) forever: hide(i := i + 1) exitif i
On 12/28/2017 6:36 PM, Jorge Manuel wrote:
When I need to draw datapoints from a external data file I’m using lua,
like this:
\starttext
\startluacode
Elemento = {}
x = {}
y ={}
z= {}
carga = {}
i=1
context("\\startMPcode”)
context("numeric u; u := 1.5cm;")
for line in io.lines("molecule.xyz
When I need to draw datapoints from a external data file I’m using lua, like this:\starttext\startluacodeElemento = {}x = {}y ={}z= {}carga = {}i=1context("\\startMPcode”)context("numeric u; u := 1.5cm;")for line in io.lines("molecule.xyz") do local a, b, c, d, e = string.match(line, '(%a+)%s*%s*