Matplotlib add gridlines not working as expected
问题 Using matplotlib subplots() in Jupyter Notebook, and using "seaborn-whitegrid" plot.style() . I am trying to add minor gridlines to my x-axis, which is in log. What am I missing? import matplotlib.pyplot as plt %matplotlib inline plt.style.use('seaborn-whitegrid') x, y = [(1, 9, 65, 142, 330), (0, 0.16, 0.50, 0.84, 1)] fig, axes = plt.subplots(3,5, figsize=(8.5,5.5), constrained_layout=True) #counter = 0 for ax in axes.flat: ax.plot(x,y) ax.set_title('Dataset-A', fontsize=8) ax.set_xlabel('x'