ScottPlot.NET
GitHub Repo stars

SignalXY Generic List

SignalXY plots support generic lists.

ScottPlot.Plot myPlot = new();

// create X and Y list with initial data
List<double> xs = new(Generate.Consecutive(count: 10, first: 0));
List<double> ys = new(Generate.RandomSample(10));

// create a signal plot from our X and Y lists
myPlot.Add.SignalXY(xs, ys);

// data can be added to lists later
xs.AddRange(Generate.Consecutive(count: 10, first: 50));
ys.AddRange(Generate.RandomSample(10));

myPlot.SavePng("demo.png", 400, 300);
This recipe is one of many in the SignalXY Plot category