- To get XPlot, scroll down to how to get XPlot or get XPlot as part of the FsLab data science package.
- For detailed documentation, scroll down to documentation or follow links on the right.
The next two demos show some of the more complex and advanced charts that can be created using XPlot. If you're getting started with XPlot, see the other documentation pages for simpler charts.
The following example uses the Google Charts library to create a combo chart showing coffee production in Bolivia, Ecuador and Madagascar (as bar plots), together with the average visualized as a line chart (full source and data]):
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11:
The XPlot library uses the F#
|> operator to configure charts. In the above example, we use
to create a basic chart and then we set a number of properties -
Chart.WithOptions specifies how the
Chart.WithLegend adds the legend that annotates the individual
The following example uses the Plotly online data analytics and visualization tool. It creates a scatter
plot, rendered on a polar chart with different marker color for each of the trials stored in the
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12:
The code snippet creates one
Scatter data series for each of the trials in the input. It sets the
properties to two lists of input values. If we wanted to produce an ordinary rectangular scatter plot, we could
instead set the
If you want to get XPlot as part of larger package of F# and .NET tools for doing data science, then check out the FsLab web site. This gives you a nice cross-platform environment where you can access data using F# Data type providers, analyze the data using Deedle data frames and series and then visualize data using XPlot.
Alternatively, you can reference XPlot via a NuGet package.
The documentation for the library is automatically generated from F# script files that you can find
docsrc/content folder on GitHub.
The links in the right panel point to a number of tutorials that demonstrate some common scenarios.
You can also copy the source code from GitHub.
Additionally, the library also comes with an API reference that is generated from code comments. This is work in progress, so please help us & contribute comments and documentation! The most important types are:
Google Chart type contains methods for creating charts like
Chart.Lineand for configuring charts like
Google Options type contains parameters for charts that are specified using
Google Configuration module contains other types that are used as parameters to
Plotly Graph module contains methods for creating various kinds of charts such as
Plotly Layout type specifies common properties of Plotly charts like title and color.