在氧气图上延伸轴

时间:2016-07-07 14:54:36

标签: c# charts oxyplot

我使用的是oxyplot,我生成的图表非常好,但我想在Y轴上保持相同的值(0到1)

我使用该代码,但它总是超过最高值(和最低值)

<table id="myList">
  <thead>
    <tr>
      <td>Product ID</td>
      <td>Product Name</td>
      <td>Quantity</td>
    </tr>
  </thead>
  <tbody>

  </tbody>
</table>

我该如何解决这个问题?

我找到的唯一方法是在0Y和1Y

上加一个空行

enter image description here

1 个答案:

答案 0 :(得分:0)

可以使用MinimumMaximum属性设置轴范围,如下所示:

model.Axes.Add(new OxyPlot.Axes.LinearAxis
            {
                Position = OxyPlot.Axes.AxisPosition.Left,
                Minimum= 0,
                Maximum= 1
            });