@@ -66,7 +66,7 @@ def query_crossid_async(self, coordinates, *, radius=5. * u.arcsec, timeout=TIME
66
66
67
67
This query returns the nearest `primary object`_.
68
68
69
- Note that there is a server-side limit of 3 arcmin on `radius`.
69
+ Note that there is a server-side limit of 3 arcmin on `` radius` `.
70
70
71
71
.. _`primary object`: https://www.sdss.org/dr17/help/glossary/#surveyprimary
72
72
@@ -129,10 +129,10 @@ def query_crossid_async(self, coordinates, *, radius=5. * u.arcsec, timeout=TIME
129
129
Raises
130
130
------
131
131
TypeError
132
- If the `radius` keyword could not be parsed as an angle.
132
+ If the `` radius` ` keyword could not be parsed as an angle.
133
133
ValueError
134
- If the `radius` exceeds 3 arcmin, or if the sizes of
135
- `coordinates` and `obj_names` do not match.
134
+ If the `` radius` ` exceeds 3 arcmin, or if the sizes of
135
+ `` coordinates`` and `` obj_names` ` do not match.
136
136
137
137
Returns
138
138
-------
@@ -208,16 +208,16 @@ def query_region_async(self, coordinates, *, radius=None,
208
208
spectro = False , field_help = False , get_query_payload = False ,
209
209
data_release = conf .default_release , cache = True ):
210
210
"""
211
- Used to query a region around given coordinates. Either `radius` or
211
+ Used to query a region around given coordinates. Either `` radius` ` or
212
212
`width` must be specified.
213
213
214
- When called with keyword `radius`, a radial or "cone" search is
214
+ When called with keyword `` radius` `, a radial or "cone" search is
215
215
performed, centered on each of the given coordinates. In this mode, internally,
216
216
this function is equivalent to the object cross-ID (`query_crossid`),
217
217
with slightly different parameters. Note that in this mode there is a server-side
218
- limit of 3 arcmin on `radius`.
218
+ limit of 3 arcmin on `` radius` `.
219
219
220
- When called with keyword `width`, and optionally a different `height`,
220
+ When called with keyword `` width`` , and optionally a different `` height` `,
221
221
a rectangular search is performed, centered on each of the given
222
222
coordinates. In this mode, internally, this function is equivalent to
223
223
a general SQL query (`query_sql`).
@@ -286,6 +286,15 @@ def query_region_async(self, coordinates, *, radius=None,
286
286
cache : bool, optional
287
287
If ``True`` use the request caching mechanism.
288
288
289
+ Raises
290
+ ------
291
+ TypeError
292
+ If the ``radius``, ``width`` or ``height`` keywords could not be parsed as an angle.
293
+ ValueError
294
+ If both ``radius`` and ``width`` are set (or neither),
295
+ or if the ``radius`` exceeds 3 arcmin,
296
+ or if the sizes of ``coordinates`` and ``obj_names`` do not match.
297
+
289
298
Examples
290
299
--------
291
300
>>> from astroquery.sdss import SDSS
@@ -307,17 +316,6 @@ def query_region_async(self, coordinates, *, radius=None,
307
316
The result of the query as a `~astropy.table.Table` object.
308
317
309
318
"""
310
- # Move Raises section here, since async_to_sync does not appear to like it.
311
- #
312
- # Raises
313
- # ------
314
- # TypeError
315
- # If the `radius`, `width` or `height` keywords could not be parsed as an angle.
316
- # ValueError
317
- # If both `radius` and `width are set (or neither),
318
- # or if the `radius` exceeds 3 arcmin,
319
- # or if the sizes of `coordinates` and `obj_names` do not match.
320
-
321
319
# Allow field_help requests to pass without requiring a radius or width.
322
320
if field_help and radius is None and width is None :
323
321
radius = 2.0 * u .arcsec
@@ -1279,7 +1277,7 @@ def _get_crossid_url(self, data_release):
1279
1277
1280
1278
def _rectangle_sql (self , ra , dec , width , height = None , cosdec = False ):
1281
1279
"""
1282
- Generate SQL for a rectangular query centered on `ra`, `dec`.
1280
+ Generate SQL for a rectangular query centered on `` ra`` , `` dec` `.
1283
1281
1284
1282
This assumes that RA is defined on the range ``[0, 360)``, and Dec on
1285
1283
``[-90, 90]``.
@@ -1293,9 +1291,11 @@ def _rectangle_sql(self, ra, dec, width, height=None, cosdec=False):
1293
1291
width : float
1294
1292
Width of rectangle in degrees.
1295
1293
height : float, optional
1296
- Height of rectangle in degrees. If not specified, `width` is used.
1294
+ Height of rectangle in degrees. If not specified, `` width` ` is used.
1297
1295
cosdec : bool, optional
1298
1296
If ``True`` apply ``cos(dec)`` correction to the rectangle.
1297
+ Otherwise, rectangles become increasingly triangle-like
1298
+ near the poles.
1299
1299
1300
1300
Returns
1301
1301
-------
@@ -1312,8 +1312,6 @@ def _rectangle_sql(self, ra, dec, width, height=None, cosdec=False):
1312
1312
d1 = dec + dd
1313
1313
if d1 > 90.0 :
1314
1314
d1 = 90.0
1315
- if d1 < d0 :
1316
- d0 , d1 = d1 , d0
1317
1315
ra_wrap = False
1318
1316
r0 = ra - dr
1319
1317
if r0 < 0 :
0 commit comments