在x轴上,通过此代码,我给标签赋予了诸如“ 0 ==>无效”和“ 1 ==>有效”之类的值:
OxyPlot.Axes.LinearAxis YAxis = new OxyPlot.Axes.LinearAxis()
{
LabelFormatter = (double arg) =>
{
if (arg == 0)
return "Invalid";
else if (arg == 1)
return "Valid";
else
return "";
},
};
我正在尝试将X值作为字符串标签,将Y(TimeSpanAxis)值作为Timespan,但是我不能。我只能将X和Y值加倍。
OxyPlot.Series.LineSeries series = new OxyPlot.Series.LineSeries()
{
//TrackerFormatString = "{X:h:mm}" + Environment.NewLine + "{Y}"
};
我该怎么做?