对于像鼻窦/鼻窦一样的波浪线我需要什么图表类型?我正在使用Windows窗体中的默认图表。
chart1.Series[0].ChartType = SeriesChartType.Line;
这是正确的图表类型吗?
另外如何在X线上显示弧度......
chart1.ChartAreas[0].AxisX.Minimum = 0 * Math.PI;
chart1.ChartAreas[0].AxisX.Maximum = 2 * Math.PI;
答案 0 :(得分:1)
这是一个适合我的例子:
var data = new List<Tuple<double,double>>();
for (double x = 0; x < Math.PI * 2; x += Math.PI / 180.0) {
data.Add(Tuple.Create(x, Math.Sin(x)));
}
chart1.ChartAreas.Add("area1");
var series = chart1.Series.Add("series1");
series.ChartType = SeriesChartType.Line;
series.ChartArea = "area1";
series.XValueMember = "Item1";
series.YValueMembers = "Item2";
chart1.DataSource = data;
结果: