GMT.jl
GMT.jl copied to clipboard
Lines plotted incorrectly on ternary diagrams when clockwise is specified
When clocwise is specified within the call to ternary() the lines are plotted in the incorrect location
b = 0:0.01:0.3
c1 = (1 .- b).^3 .- 0.7^3
c2 = (1 .- 2*b).^2 .- 0.4^2
# Generate the coordinates of two lines.
t1 = GMT.tern2cart([(1 .- b .- c1) b c1]) # Note that GMT.jl function expects a Mx3 matrix
t2 = GMT.tern2cart([(1 .- b .- c2) b c2])
GMT.ternary(labels=("A", "B", "C"), clockwise=true)
GMT.plot!(t1, lw=2, lc=:red, ls="line& (a) &") # line style -> fancy stuff
GMT.plot!(t2, lw=2, lc=:blue)
GMT.text!(GMT.tern2cart([0.3 0.4 0.3]), text="Umbilicus", font=18, show=true)

This occurs whether clockwise is specified as true or false. I suspect this is because clockwise=false appears to have an identical affect to clockwise=true.
Hmm, very tricky. The problem is that plot and text know nothing about ternary clockwise, and can never know. That will have to be a job of tern2cart