FSharp.Charting
FSharp.Charting copied to clipboard
[Docs] Add an example for a sclatter plot with labels on the points
It's not obvious how to do it at first thought, and it's a very common plot
Let me rephrase that. I's obvious how to show the labels Chart.Point(points, Labels=labels), but usually the output of that is not what you wanted:

Most of the time you want something like this instead:

and to obtain that you need something like this:
points
|> Seq.zip labels
|> Seq.groupBy fst
|> Seq.map (fun (label, points) -> Chart.Point(Seq.map snd points).WithDataPointLabels(label))
|> Chart.Combine