Repository: holoviz/holoviews

Issue:
Scatter polar projection main plot disappears when theta above 5.3 radians 
#### ALL software version info
hv version '1.14.9'

```
        
IPython          : 8.2.0
        ipykernel        : 6.13.0
        ipywidgets       : 7.7.0
        jupyter_client   : 7.2.2
        jupyter_core     : 4.9.2
        jupyter_server   : not installed
        jupyterlab       : not installed
        nbclient         : 0.6.0
        nbconvert        : 6.5.0
        nbformat         : 5.3.0
        notebook         : 6.4.11
        qtconsole        : 5.3.0
        traitlets        : 5.1.1
```


Chrome Version 104.0.5112.81 (Official Build) (64-bit)

#### Description of expected behavior and the observed behavior

 I am having trouble with the display of polar Scatter when the values go above 5.3 radians. Most of the plot disappears.


```
hv.extension('matplotlib')

theta = np.arange(0, 5.4, 0.1)

r = np.ones(len(theta))

scatter = hv.Scatter((theta, r), 'theta', 'r')
scatter.options(projection='polar', show_grid=True)

```

![image](https://user-images.githubusercontent.com/12778156/185417466-5e8d370a-611b-4483-9659-7369e5ed8932.png)


If you reduce the radian value then it is okay

```
hv.extension('matplotlib')

theta = np.arange(0, 5.3, 0.1)

r = np.ones(len(theta))

scatter = hv.Scatter((theta, r), 'theta', 'r')
scatter.options(projection='polar', show_grid=True)
```
![image](https://user-images.githubusercontent.com/12778156/185417749-01d389c3-d3c2-4453-bfd9-af5326dbbb01.png)




Discussion:
Note the curve works okay

```
hv.extension('matplotlib')

theta = np.arange(0, 5.4, 0.1)

r = np.ones(len(theta))

scatter = hv.Curve((theta, r), 'theta', 'r')
scatter.options(projection='polar', show_grid=True)
```

![image](https://user-images.githubusercontent.com/12778156/185418564-b0a7ee7c-0323-4db1-b248-61ebef84aa1a.png)

Thanks for reporting this issue!

The fact that Curves work but Scatters in this case does indicate something strange is going on (i.e. a bug!)

Resolving patch:
diff --git a/holoviews/plotting/mpl/element.py b/holoviews/plotting/mpl/element.py
--- a/holoviews/plotting/mpl/element.py
+++ b/holoviews/plotting/mpl/element.py
@@ -336,6 +336,10 @@ def _set_axis_limits(self, axis, view, subplots, ranges):
                     axis.set_zlim(bottom=zmin)
                 if valid_lim(zmax):
                     axis.set_zlim(top=zmax)
+        elif isinstance(self.projection, str) and self.projection == "polar":
+            _, b, _, t = coords
+            l = 0
+            r = 2 * np.pi
         else:
             l, b, r, t = coords
 


Test patch:
diff --git a/holoviews/tests/plotting/matplotlib/test_elementplot.py b/holoviews/tests/plotting/matplotlib/test_elementplot.py
--- a/holoviews/tests/plotting/matplotlib/test_elementplot.py
+++ b/holoviews/tests/plotting/matplotlib/test_elementplot.py
@@ -7,6 +7,8 @@
 from .test_plot import TestMPLPlot, mpl_renderer
 
 from matplotlib.ticker import FormatStrFormatter, FuncFormatter, PercentFormatter
+from matplotlib.projections import PolarAxes
+
 
 class TestElementPlot(TestMPLPlot):
 
@@ -149,6 +151,14 @@ def test_element_zformatter_instance(self):
         zformatter = zaxis.get_major_formatter()
         self.assertIs(zformatter, formatter)
 
+    def test_element_polar_xlimits(self):
+        theta = np.arange(0, 5.4, 0.1)
+        r = np.ones(len(theta))
+        scatter = Scatter((theta, r), 'theta', 'r').opts(projection='polar')
+        plot = mpl_renderer.get_plot(scatter)
+        ax = plot.handles['axis']
+        self.assertIsInstance(ax, PolarAxes)
+        self.assertEqual(ax.get_xlim(), (0, 2 * np.pi))
 
 
 class TestColorbarPlot(TestMPLPlot):