I mistakenly ran the wrong syntax
plt.xlabel = 'Sample size', which converted the
plt.xlabel attribute to a string and resulted in a
'str' object not callable error.
Now, I am trying to run the correct syntax
plt.xlabel('Sample size') after restoring the initial code but I am getting the same error.
It worked when I ran it after my code having the same syntax had worked on the next screen.
If this happens again, here is a workaround: