ScottPlot.NET
GitHub Repo stars

Grid with Top Axis

Grid lines use the bottom and left axes by default, but this behavior can be customized for plots which use other axes.

This code sample is specific to ScottPlot 5 (details)
ScottPlot.Plot myPlot = new();

var sig = myPlot.Add.Signal(ScottPlot.Generate.Sin());
sig.Axes.XAxis = myPlot.Axes.Top;
myPlot.Grid.XAxis = myPlot.Axes.Top;

myPlot.SavePng("demo.png", 400, 300);

Edit on GitHub