Ternary Plot example

A forum dedicated to WPF version of LightningChart Ultimate.

Moderator: Arction_LasseP

Posts: 38
Joined: Fri Dec 06, 2013 4:51 pm

Ternary Plot example

Post by Greg9504 » Fri Mar 11, 2016 3:07 pm

I took a quick look at the sample for Ternary plots. The example allows the plot to be a non equilateral (Isosceles) triangle. This is no longer a Ternary plot, the triangle should remain equilateral. I added this code at line 403:

vXY.ZoomPanOptions.AspectRatioOptions.AspectRatio = ViewAspectRatio.Manual;
vXY.ZoomPanOptions.AspectRatioOptions.ManualAspectRatioWH = 1;

This seems to make the plot remain equilateral when the window is resized.

Posts: 400
Joined: Mon Mar 14, 2016 9:22 am

Re: Ternary Plot example

Post by ArctionKestutis » Mon Mar 14, 2016 11:25 am

The Ternary Plot example was made with assumption that user want to fill whole area with chart. This assumption maybe wrong, but internally (x-y axis coordinates) triangle is still equilateral. Therefore, all coordinate calculations should work fine. Your suggestion is very elegant and simple way to satisfy all needs. We will add one more property in the next release, which would allow user to switch between equilateral or fill-chart view.