Skip to content

Unable to use a collection for hover data in XPlot.Plotly.Scattergl  #165

Open

Description

@lcorrigan

Using an array as the source data for hover doesn't work with the Scattergl plot, but does with the non-gl scatter plot. The GL will only accept a string.

I use a custom formatter for the hover text for example:
var ht = Samples.Select(x => $"Time (EST): {x.TimeStampEST}<br>Current (mA): {x.CurrentAmps * 1000}<br>").ToArray();
but the non-GL scatter's performance was choking so I tried the GL scatter and saw wouldn't accept it.

I'm using C# .NET Framework, with XPlot.Plotly 4.0.1 in LinqPad 5, but also tried it in the C# jupyter binder via one of the links in the help file. I wasn't able to get that to run as-is, until I changed the XPlot nuget reference to 4.0.1. The attached screen capture is from the binder, and shows the scatter plot accepting the array but the scattergl rejecting it. The ability to create an interactive graph in an HTML file with other report data has been awesome but without the scattergl, it's just too slow to update for interactive use. I used to use the scattergl like this in python, and would really like to see it again but in .NET if possible.

Activity

  1. lcorrigan commented on Apr 3, 2021

    @lcorrigan
    Author

    scatterGL wont accept array for hovertext

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions