I’m trying to make a simple graph with some curves overlaid on a scatterplot.
My code look something like this:
p = plot_ly(curve_data_all, x = Concentration, y = GR, color = exp)
p %>% add_trace(p, x = test_plot$concentration, y = test_plot$GR, mode = “markers”, color = test_plot$experiment)
layout(p, xaxis = list(type = “log”),
title = “GR value vs. Concentration”,
xaxis = list(title = “Concentration”, range = c(0,10)),
yaxis = list(title = “GR”, range = c(0,1)))
The problem is that when I run this code, it produces a log-scaled plot with curves, but without the points that should have been added in “add_trace”. If I comment out the “layout” section, the plot shows both curves and points like I want, but it’s not on a log-scale, which I need.