.. DO NOT EDIT. .. THIS FILE WAS AUTOMATICALLY GENERATED BY SPHINX-GALLERY. .. TO MAKE CHANGES, EDIT THE SOURCE PYTHON FILE: .. "_auto_examples/set_minor_log_ticks.py" .. LINE NUMBERS ARE GIVEN BELOW. .. only:: html .. note:: :class: sphx-glr-download-link-note :ref:`Go to the end ` to download the full example code. .. rst-class:: sphx-glr-example-title .. _sphx_glr__auto_examples_set_minor_log_ticks.py: Set Minor Log Ticks ===================================== :func:`sysplot.set_minor_log_ticks` adds unlabeled minor ticks at every subdivision of a logarithmic axis. Tick direction is controlled by ``tick_direction`` and defaults to :attr:`~sysplot.SysplotConfig.tick_direction`. .. GENERATED FROM PYTHON SOURCE LINES 8-36 .. image-sg:: /_auto_examples/images/sphx_glr_set_minor_log_ticks_001.png :alt: tick_direction="in", tick_direction="out", tick_direction="inout" :srcset: /_auto_examples/images/sphx_glr_set_minor_log_ticks_001.png :class: sphx-glr-single-img .. code-block:: Python import numpy as np import matplotlib.pyplot as plt import sysplot as ssp ssp.apply_config() x = np.logspace(0, 3, 300) y = 1 / x fig, axes = plt.subplots(1, 3, figsize=ssp.get_figsize(ncols=3)) axes[0].set_xscale("log") axes[0].plot(x, y) ssp.set_minor_log_ticks(axis=axes[0].xaxis, tick_direction="in") axes[0].set(title='tick_direction="in"', xlabel="frequency", ylabel="magnitude") axes[1].set_xscale("log") axes[1].plot(x, y) ssp.set_minor_log_ticks(axis=axes[1].xaxis, tick_direction="out") axes[1].set(title='tick_direction="out"', xlabel="frequency") axes[2].set_xscale("log") axes[2].plot(x, y) ssp.set_minor_log_ticks(axis=axes[2].xaxis, tick_direction="inout") axes[2].set(title='tick_direction="inout"', xlabel="frequency") plt.show() .. rst-class:: sphx-glr-timing **Total running time of the script:** (0 minutes 0.752 seconds) .. _sphx_glr_download__auto_examples_set_minor_log_ticks.py: .. only:: html .. container:: sphx-glr-footer sphx-glr-footer-example .. container:: sphx-glr-download sphx-glr-download-jupyter :download:`Download Jupyter notebook: set_minor_log_ticks.ipynb ` .. container:: sphx-glr-download sphx-glr-download-python :download:`Download Python source code: set_minor_log_ticks.py ` .. container:: sphx-glr-download sphx-glr-download-zip :download:`Download zipped: set_minor_log_ticks.zip ` .. only:: html .. rst-class:: sphx-glr-signature `Gallery generated by Sphinx-Gallery `_