Dash.jl icon indicating copy to clipboard operation
Dash.jl copied to clipboard

Plotting of NaN values

Open jkrimmer opened this issue 2 years ago • 3 comments

Apparently, moving to the JSON3 package broke the plotting of traces containing NaN values.

 Error: error handling request
│   exception =
│    NaN not allowed to be written in JSON spec

I would expect using JSON3.write with the allow_inf flag set to true to resolve this issue.

Further information: Julia v1.7.0 Dash v1.1.1 PlotlyJS v0.18.8

jkrimmer avatar Jan 12 '22 14:01 jkrimmer

Unfortunately, using the allow_inf flag only allows writing the JSON files containing NaN values. However, dash cannot plot these values... I have not figured out how to resolve this issue, yet.

jkrimmer avatar Jan 13 '22 18:01 jkrimmer

Maybe you can use nothing to jump over the inf? ref

HackYardo avatar Jan 29 '22 06:01 HackYardo

Thanks a lot for the suggestion, using nothing instead of Inf or NaN circumvents the issue. Maybe it would be nice to have this replacement happening inside Dash?

jkrimmer avatar Feb 04 '22 10:02 jkrimmer