Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.
How to: Draw a Custom Function in the 2D Scatter Line Chart
2 minutes to read
This example demonstrates how to draw an Archimedian Spiral function in the Scatter Line chart. To do this, it is necessary to add a LineScatterSeries2D object to the diagram’s Diagram.Series collection and then programmatically add series points to it.
For more information, see the CreateArchimedianSpiralPoints method’s implementation below.
ImportsMicrosoft.VisualBasicImportsSystemImportsSystem.WindowsImportsDevExpress.Xpf.ChartsNamespace ScatterLineChartWithCustomFunction
PartialPublicClass MainWindow
Inherits Window
PublicSubNew()
InitializeComponent()
CreateArchimedianSpiralPoints()
EndSubPrivateSub CreateArchimedianSpiralPoints()
For i AsInteger = 0To719Step15Dim t AsDouble = CDbl(i) / 180 * Math.PI
Dim x AsDouble = t * Math.Cos(t)
Dim y AsDouble = t * Math.Sin(t)
ArchimedianSpiral.Points.Add(New SeriesPoint(x, y))
Next i
EndSubEndClassEndNamespace
Was this page helpful?
Thanks for your feedback!
How can we improve this help topic?
Additional comments/thoughts:
If you have any questions, submit a ticket to our Support Center.