def select_ellipse(self, x, y, xc, yc, width, height, angle=<NUM_LIT:0>, mode="<STR_LIT:replace>", name="<STR_LIT:default>", radians=False, inclusive=True):
<EOL>if radians:<EOL><INDENT>pass<EOL><DEDENT>else:<EOL><INDENT>alpha = np.deg2rad(angle)<EOL><DEDENT>xr = width / <NUM_LIT:2><EOL>yr = height / <NUM_LIT:2><EOL>r = max(xr, yr)<EOL>a = xr / r<EOL>b = yr / r<EOL>expr = "<STR_LIT>".format(**locals())<EOL>if inclusive:<EOL><INDENT>expr = ((self[x] - xc) * np.cos(alpha) + (self[y] - yc) * np.sin(alpha))**<NUM_LIT:2> / a**<NUM_LIT:2> + ((self[x] - xc) * np.sin(alpha) - (self[y] - yc) * np.cos(alpha))**<NUM_LIT:2> / b**<NUM_LIT:2> <= r**<NUM_LIT:2><EOL><DEDENT>else:<EOL><INDENT>expr = ((self[x] - xc) * np.cos(alpha) + (self[y] - yc) * np.sin(alpha))**<NUM_LIT:2> / a**<NUM_LIT:2> + ((self[x] - xc) * np.sin(alpha) - (self[y] - yc) * np.cos(alpha))**<NUM_LIT:2> / b**<NUM_LIT:2> < r**<NUM_LIT:2><EOL><DEDENT>self.select(boolean_expression=expr, mode=mode, name=name)<EOL>
Select an elliptical region centred on xc, yc, with a certain width, height
and angle.

Example:

>>> df.select_ellipse('x','y', 2, -1, 5,1, 30, name='my_ellipse')

:param x: expression for the x space
:param y: expression for the y space
:param xc: location of the centre of the ellipse in x
:param yc: location of the centre of the ellipse in y
:param width: the width of the ellipse (diameter)
:param height: the width of the ellipse (diameter)
:param angle: (degrees) orientation of the ellipse, counter-clockwise
              measured from the y axis
:param name: name of the selection
:param mode:
:return: