Setting axes.linewidth without changing the rcParams global dict

This answer does not work, as it is explained in the comments. I suggest using spines. As mentioned in a comment by Czechnology, consider changing the ticks too. import matplotlib.pyplot as plt fig, (ax1, ax2) = plt.subplots(1, 2, figsize=(10, 4)) ax1.set_title(‘Normal spine and ticks’) ax2.set_title(‘Adjusted spine and ticks’) # change each spine separately: # ax.spines[‘right’].set_linewidth(0.5) … Read more

Matplotlib log scale tick label number formatting

Sure, just change the formatter. For example, if we have this plot: import matplotlib.pyplot as plt fig, ax = plt.subplots() ax.axis([1, 10000, 1, 100000]) ax.loglog() plt.show() You could set the tick labels manually, but then the tick locations and labels would be fixed when you zoom/pan/etc. Therefore, it’s best to change the formatter. By default, … Read more

Putting newline in matplotlib label with TeX in Python?

You can have the best of both worlds: automatic “escaping” of LaTeX commands and newlines: plt.ylabel(r”My long label with unescaped {\LaTeX} $\Sigma_{C}$ math” “\n” # Newline: the backslash is interpreted as usual r”continues here with $\pi$”) (instead of using three lines, separating the strings by single spaces is another option). In fact, Python automatically concatenates … Read more

matplotlib set yaxis label size

If you are using the ‘pylab’ for interactive plotting you can set the labelsize at creation time with pylab.ylabel(‘Example’, fontsize=40). If you use pyplot programmatically you can either set the fontsize on creation with ax.set_ylabel(‘Example’, fontsize=40) or afterwards with ax.yaxis.label.set_size(40).

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)