Skip to content

Commit

Permalink
feat(plot): set the locator of the major ticker (#311)
Browse files Browse the repository at this point in the history
  • Loading branch information
RDWimmers committed Mar 31, 2023
1 parent be40863 commit af773da
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/pygef/plotting.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

import matplotlib.patches as mpatches
import matplotlib.pyplot as plt
import matplotlib.ticker as plticker
import numpy as np
from matplotlib.gridspec import GridSpec

Expand All @@ -16,6 +17,7 @@
ctx = None

FigureSize = (8, 12)
TickLoc = plticker.MultipleLocator(base=0.5)


def plot_cpt(
Expand Down Expand Up @@ -79,6 +81,7 @@ def plot_cpt(
ax.grid(which="both")
ax.grid(which="minor", alpha=0.2)
ax.grid(which="major", alpha=0.5)
ax.yaxis.set_major_locator(TickLoc)

# set the properties on the localFriction axes
ax2.xaxis.set_ticks_position("top")
Expand Down Expand Up @@ -197,6 +200,7 @@ def plot_bore(
else:
ax.set_ylabel("depth [m]")
ax.set_xlabel("cumulative soil fraction [-]")
ax.yaxis.set_major_locator(TickLoc)

for i in range(5):
ax.fill_betweenx(
Expand Down

0 comments on commit af773da

Please sign in to comment.