Pre loader

Plotting un-ordered xy values

Welcome to the SciChart Forums!

  • Please read our Question Asking Guidelines for how to format a good question
  • Some reputation is required to post answers. Get up-voted to avoid the spam filter!
  • We welcome community answers and upvotes. Every Q&A improves SciChart for everyone

WPF Forums | JavaScript Forums | Android Forums | iOS Forums

0
0

i have the data values as shown below.
0″,”0.1004″
“0”,”0″
“0”,”0.200801″
“0”,”0.1004″
“0”,”0″
“0”,”0″
“0”,”0.1004″
“0”,”0.1004″
“0”,”0″
“0”,”0″
“0”,”0.200801″
“0”,”0″
“0”,”0.1004″
“0”,”0″
“0”,”-0.1004″
“0”,”-0.1004″
“0”,”0″
“-0.409378″,”0”
“-1.09167″,”-0.200801″
“-1.77397″,”-0.1004″
“-2.86565″,”-0.200801″
“-4.3667″,”-0.1004″
“-5.73129″,”-0.200801″
“-7.50526″,”-0.200801″
“-9.4157″,”-0.200801″
“-11.872″,”-0.200801″
“-14.4647″,”-0.200801″
“-16.921″,”0”
“-20.196″,”-0.1004″
“-23.471″,”-0.301201″
“-26.6096″,”0”
“-30.5669″,”-0.1004″
“-34.5242″,”-0.301201″
“-38.4815″,”-0.200801″
“-43.2576″,”-0.200801″
“-47.8972″,”0”
“-52.5368″,”-0.1004″
“-57.9952″,”-0.301201″
“-63.3171″,”0.1004”
“-68.7755″,”0”
“-74.2339″,”-0.1004″
“-79.5558″,”0.1004”
“-85.0142″,”-0.200801″
“-90.3361″,”0”
“-95.7945″,”-0.200801″
“-101.253″,”-0.1004″
“-106.575″,”0”
“-112.033″,”0”
“-117.355″,”0”
“-122.813″,”-0.200801″
“-128.272″,”0”
“-133.594″,”0.1004”
“-139.052″,”0.1004”
“-144.374″,”0.301201”
“-149.832″,”0”
“-155.154″,”0”
“-160.613″,”-0.1004″
“-166.071″,”0.1004”
“-171.393″,”0”
“-176.851″,”-0.1004″
“-182.173″,”-0.301201″
“-187.632″,”0”
“-193.09″,”-0.1004″
“-198.412″,”-0.301201″
“-203.87″,”0”
“-209.192″,”-0.200801″
“-214.651″,”-0.401601″
“-220.109″,”0”
“-225.431″,”-0.200801″
“-230.889″,”-0.1004″
“-236.211″,”0”
“-241.67″,”0”
“-246.991″,”0”
“-252.45″,”-0.301201″
“-257.908″,”0.1004”
“-263.23″,”0”
“-268.688″,”-0.301201″
“-274.01″,”-0.1004″
“-279.469″,”0”
“-284.927″,”-0.301201″
“-290.249″,”0”
“-295.707″,”0”
“-301.029″,”0.1004”
“-306.488″,”0”
“-311.946″,”-0.301201″
“-317.268″,”0.1004”
“-322.726″,”0”
“-328.048″,”-0.301201″
“-333.507″,”0”
“-338.829″,”-0.301201″
“-344.287″,”-0.1004″
“-349.745″,”-0.301201″
“-355.067″,”-0.301201″
“-360.526″,”-0.301201″
“-365.848″,”-0.1004″
“-370.897″,”-0.401601″
“-376.355″,”-0.301201″
“-381.813″,”-0.401601″
“-387.135″,”-0.301201″
“-392.594″,”-0.1004″
“-397.915″,”0”
“-403.374″,”-0.301201″
“-408.696″,”-0.301201″
“-414.154″,”-0.200801″
“-419.612″,”0”
“-424.934″,”0”
“-430.393″,”0.1004”
“-435.715″,”0”
“-441.173″,”-0.200801″
“-446.631″,”-0.1004″
“-451.953″,”-0.301201″
“-457.412″,”-0.1004″
“-462.734″,”-0.1004″
“-468.192″,”-0.1004″
“-473.65″,”0”
“-478.972″,”0”
“-484.431″,”0”
“-489.753″,”0”
“-495.211″,”-0.1004″
“-500.533″,”0”

.3382″,”0.401601″
“109.44”,”-0.1004″
“125.679”,”0.301201″
“141.918”,”0.401601″
“158.156”,”0.200801″
“174.259”,”0.301201″
“190.497”,”-0.1004″
“206.736”,”-0.1004″
“222.975”,”0.200801″
“239.077”,”0.200801″
“255.315”,”0.401601″
“271.554”,”0.200801″
“287.793”,”0.1004″
“303.895”,”0.200801″
“320.134”,”0.1004″
“336.372”,”0.301201″
“352.611”,”-0.200801″
“368.85”,”-0.200801″
“384.952”,”0.200801″
“401.19”,”0.1004″
“417.429”,”0.1004″
“433.668”,”0.200801″
“449.77”,”-0.301201″
“466.009”,”0.502002″
“482.247”,”0.200801″
“498.077”,”0.602402″
“514.315”,”0.1004″
“530.554”,”-0.1004″
“546.656”,”-0.1004″
“562.895”,”0.200801″
“579.133”,”-0.200801″
“595.372”,”0.1004″
“611.474”,”0.301201″
“627.713”,”-0.200801″
“643.952”,”0.200801″
“660.19”,”0.200801″
“676.293”,”-0.301201″
“692.531”,”0.200801″
“708.77”,”-0.200801″
“725.009”,”0.1004″
“741.111”,”0.200801″
“757.349”,”-0.200801″
“773.588”,”0.200801″
“789.827”,”-0.301201″
“806.065”,”-0.401601″
“822.168”,”0.301201″
“838.406”,”-0.602402″
“854.645”,”0.200801″
“870.884”,”-0.1004″
“886.986”,”0.200801″
“903.224”,”0.301201″
“919.463”,”0.200801″
“935.702”,”0.301201″
“951.804”,”-0.200801″
“968.043”,”-0.301201″
“984.281”,”0.200801″
“1000.52”,”0″
“1016.62”,”0.1004″
“1032.86”,”-0.200801″
“1049.1”,”-0.401601″
“1065.34”,”0″
“1081.58”,”0.1004″
“1097.68”,”0.200801″
“1113.92”,”-0.200801″
“1130.16”,”-0.301201″
“1146.4”,”-0.1004″
“1162.5”,”0.200801″
“1178.74”,”0.301201″
“1194.97”,”0.401601″
“1211.21”,”0.301201″
“1227.32”,”0.401601″
“1243.55”,”0.1004″
“1259.79”,”0.200801″
“1276.03”,”-0.200801″
“1292.13”,”-0.401601″
“1308.37”,”-0.200801″
“1324.61”,”0.200801″
“1340.85”,”0.200801″
“1357.09”,”0.1004″
“1373.19”,”-0.301201″
“1389.43”,”0.301201″
“1405.67”,”-0.401601″
“1421.91”,”0.301201″
“1438.01”,”-0.301201″
“1454.25”,”0.301201″
“1470.49”,”-0.200801″
“1486.72”,”-0.301201″
“1502.83”,”0.301201″
“1519.07”,”0.301201″
“1535.3”,”-0.602402″
“1551.54”,”0.200801″
“1567.65”,”-0.401601″
“1583.88”,”-0.200801″
“1600.12”,”0.1004″
“1616.36”,”0.200801″
“1632.6”,”0.1004″
“1648.7”,”-0.301201″
“1664.94”,”0.200801″
“1681.18”,”0.301201″
“1697.42”,”0.401601″
“1713.52”,”-0.401601″
“1729.35”,”-0.200801″
“1746”,”-0.301201″
“1762.24”,”0.1004″
“1778.07”,”0.1004″
“1794.3”,”0″
“1810.82”,”0.1004″
“1827.05”,”0.1004″
“1842.88”,”0″
“1859.12”,”0.200801″
“1875.63”,”0.200801″
“1891.87”,”-0.301201″
“1907.7”,”0.1004″
“1923.94”,”-0.301201″
“1940.45”,”0.401601″
“1956.69”,”-0.200801″
“1972.52”,”0.200801″
“1988.76”,”-0.200801″
“2004.86”,”-0.301201″
“2021.1”,”0.200801″
“2037.34”,”-0.1004″
“2053.58”,”0.301201″
“2069.82”,”0.1004″

But the negative values are not plotted when XAxis is set to AutoRange? Does the dataset need to be ordered for the graph to render properly? How do I set the range to display negative values. I am using FastLinerenderable series.

  • You must to post comments
0
0

Hi there,

That’s right, SciChart’s standard data-series expect the data to be sorted in the X-Direction. From our FAQ:

SciChart expects data in the X-Axis to be sorted in ascending order. The main reason for this is speed – sorted data can be indexed efficiently using binary search, allowing for transformations and rendering of many millions of data-points instantly!

The drawback is you have to ensure your data is sorted on the X-Axis. This shouldn’t be a problem, the SciChart DataSeries accept IEnumerable input so you can write a short LINQ query to sort before appending.

If you must display unsorted data (e.g. charts looping back on themselves), you can use the UnsortedXyDataSeries. Please see our Oscillosope Demo -> Change DataSource to Lissajous for a demo of this.

Best regards,
Andrew

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.

Try SciChart Today

Start a trial and discover why we are the choice
of demanding developers worldwide

Start TrialCase Studies