How can I plot a steam plot without markers (only steam lines)?. It is specially useful when plotting really long signal arrays.
Thanks!
MatPlotLib with Python To prevent scientific notation, we must pass style='plain' in the ticklabel_format method.
The reason your plot is blank is that matplotlib didn't auto-adjust the axis according to the range of your patches. Usually, it will do the auto-adjust jobs with some main plot functions, such as plt. plot(), plt.
Plotting from an IPython shell draw() . Using plt. show() in Matplotlib mode is not required.
show() and plt. draw() are unnecessary and / or blocking in one way or the other.
You can simply set the marker to be nothing:

import matplotlib.pyplot as plt
import numpy as np
x = np.linspace(0, 6*np.pi, 200)
y = np.sin(x)
plt.stem(x, y, markerfmt=" ")
plt.show()
In matplotlib, there are a few ways to use "nothing" as the marker, and each gives a somewhat different result. For example, using "" instead of " " will connect the ends of the stem with a line:

Also, btw, I first tried using a pixel marker, specified by ",", but this pixel ended up not being well aligned with the stem and didn't look good.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With