Thanks in advance for the help, I have stumbled through a ton of documentation and can’t seem to find an answer what feels like should be a simple question. I am trying to create a scatter plot with Plotly that has a continuous number x variable, continuous number y variable, and a categorical color variable. What I would like to do is create a plot where there different scatter traces based on the categorical color variable. This seems to be really straightforward with Plotly Express, but I am trying to avoid writing server code for graph generation and use the Plotly go.scatter module on the front end instead. Here is an example similar what I want I am looking to do:
My input data for the graph is three arrays that are structured similar to this:
x = [0.1, 0.2, 0.3, 0.4, n]
y = [0.6, 0.5, 0.4, 0.3, n]
color = [‘blue’, ‘white’, ‘blue’, ‘red’, n]
I want to be able to produce the scatter plot and be able to enable / disable the color traces. Hope this makes sense!
Ethan