Skip to content

Commit

Permalink
Fix the xlim of polar plots
Browse files Browse the repository at this point in the history
  • Loading branch information
mdboom committed Dec 17, 2012
1 parent fdc4154 commit eb8fa7b
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions lib/matplotlib/projections/polar.py
Expand Up @@ -57,14 +57,10 @@ def transform_non_affine(self, tr):
t *= theta_direction
t += theta_offset

if rmin != 0:
r = r - rmin
mask = r < 0
x[:] = np.where(mask, np.nan, r * np.cos(t))
y[:] = np.where(mask, np.nan, r * np.sin(t))
else:
x[:] = r * np.cos(t)
y[:] = r * np.sin(t)
r = r - rmin
mask = r < 0
x[:] = np.where(mask, np.nan, r * np.cos(t))
y[:] = np.where(mask, np.nan, r * np.sin(t))

return xy
transform_non_affine.__doc__ = Transform.transform_non_affine.__doc__
Expand Down Expand Up @@ -779,4 +775,3 @@ def drag_pan(self, button, key, x, y):
# result = self.transform(result)
# return mpath.Path(result, codes)
# transform_path_non_affine = transform_path

0 comments on commit eb8fa7b

Please sign in to comment.