| |||||
Introducing SharpPlot Your First Chart Recent Updates Tutorials General Tutorials Chart Tutorials Reference SharpPlot Class Properties Methods Structures Enumerations Style examples Glossaries Active Charts VectorMath Class DBUtil Class Get SharpPlot Download SharpPlot Buying SharpPlot SharpPlot Support Upgrading from GraPL Release notes |
Home > Sample Charts > DialChart > A Simple Dial to Show One Value A Simple Dial to Show One ValueThe Dial or Gauge chart is often used to present a single value (maybe a benchmark index of company performance) in the context of an expected or desired range. The value on its own may mean very little (maybe our production plant made 23% rejects last week) until it is set in the context of the expected range. This chart has a simple pointer, and adds a datum line to show a reasonable maximum value. Note that the x-range is used to range the dial here, and is always required as SharpPlot has no way to guess the correct range from a single data point. SharpPlot sp = new SharpPlot; sp.SetMargins(24,24,12,12); sp.Heading = "Simple Pointer and Scale"; sp.SetAxisStyle(Color.Navy,LineStyle.Solid,1.2); sp.SetXLabelFont("Arial",12,FontStyle.Bold); sp.SetPenWidths(2); sp.SetXRange(30); sp.SetXTickMarks(5,4); sp.SetDatumLineStyle(Color.Red,LineStyle.Dash,0.8); sp.SetXDatumLines(25); sp.DrawDialChart(17); Worked Examples |