Here is the graph of which I would like to determine the peaks. When I’ve done that, I would like to connect the dots. However I have no clue how to actually make this happen. Below is the code I currently have, but it sets markers all across my line graph from the first picture. Please help!
@joziask, I think I answered a similar question some time ago:
@nogons welcome to the forums.
Yes, you can do that. You just have to add a trace with the minimum values:
import numpy as np
import plotly.express as px
# create data
arr = np.random.randint(0, 2000, size=(10, 30))
# create base figure
fig = px.scatter(arr)
# add trace with minimum values
How do you define a peak, that would be the question.
Scipy has actually module for peak detection:
A first search on stackoverflow shows some example usages:
Unfortunately it does not work yet. I’ve created an array of the values in my graph, but I get the following error.
@joziask , what’s the shape of