nesticot commited on
Commit
fbc11e1
·
verified ·
1 Parent(s): 47531b9

Update functions/PitchPlotFunctions.py

Browse files
Files changed (1) hide show
  1. functions/PitchPlotFunctions.py +10 -0
functions/PitchPlotFunctions.py CHANGED
@@ -378,6 +378,16 @@ class PitchPlotFunctions:
378
 
379
  # Set aspect ratio and apply clipping
380
  ax.set_aspect('equal', adjustable='box')
 
 
 
 
 
 
 
 
 
 
381
 
382
  # Ensure all plot elements are clipped to the data area
383
  for child in ax.get_children():
 
378
 
379
  # Set aspect ratio and apply clipping
380
  ax.set_aspect('equal', adjustable='box')
381
+
382
+ ax.set_position([0.15, 0.15, 0.7, 0.7])
383
+
384
+ # Get the bbox from the axis data area
385
+ bbox = ax.get_window_extent().transformed(ax.figure.dpi_scale_trans.inverted())
386
+
387
+ # Set clip box for the main plot area
388
+ ax.set_clip_box(bbox)
389
+ ax.set_clip_on(True)
390
+
391
 
392
  # Ensure all plot elements are clipped to the data area
393
  for child in ax.get_children():