I have the following program to detect all the peaks on a line graph. It succesfully detects the peaks but I only want for it to detect the ones which are conspicous(large enough to be seen). Any suggestions?
import numpy as np
b = (X[1:]-X[:-1])[:-1]
c = (X[:-1]-X[1:])[1:]
minima = np.where(np.bitwise_and(b<0, c<0))[0]+1
maxima = np.where(np.bitwise_and(b>0, c>0))[0]+1
all_peaks = np.where((b*c)>0)[0]+1
del b,c
print(minima)
print(maxima)
print(all_peaks)