{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "### SIMBAD" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [], "source": [ "from astroquery.simbad import Simbad" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " MAIN_ID RA DEC ... COO_WAVELENGTH COO_BIBCODE \n", " \"h:m:s\" \"d:m:s\" ... \n", "--------- ------------- ------------- ... -------------- -------------------\n", "* alf CMa 06 45 08.9172 -16 42 58.017 ... O 2007A&A...474..653V\n" ] } ], "source": [ "result_table = Simbad.query_object(\"Sirius\")\n", "result_table.pprint(show_unit=True)" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [ { "data": { "text/html": [ "Table masked=True length=1\n", "\n", "\n", "\n", "\n", "\n", "
MAIN_IDRADECRA_PRECDEC_PRECCOO_ERR_MAJACOO_ERR_MINACOO_ERR_ANGLECOO_QUALCOO_WAVELENGTHCOO_BIBCODE
"h:m:s""d:m:s"masmasdeg
objectstr13str13int16int16float32float32int16str1str1object
* alf CMa06 45 08.9172-16 42 58.0179911.70010.90090AO2007A&A...474..653V
" ], "text/plain": [ "\n", " MAIN_ID RA DEC ... COO_WAVELENGTH COO_BIBCODE \n", " \"h:m:s\" \"d:m:s\" ... \n", " object str13 str13 ... str1 object \n", "--------- ------------- ------------- ... -------------- -------------------\n", "* alf CMa 06 45 08.9172 -16 42 58.017 ... O 2007A&A...474..653V" ] }, "execution_count": 3, "metadata": {}, "output_type": "execute_result" } ], "source": [ "result_table" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [], "source": [ "from astropy import coordinates\n", "import astropy.units as u" ] }, { "cell_type": "code", "execution_count": 5, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " MAIN_ID RA ... COO_WAVELENGTH COO_BIBCODE \n", " \"h:m:s\" ... \n", "----------------------- ------------- ... -------------- -------------------\n", " NAME Ori Region 05 35 17.30 ... O \n", " ... ... ... ... ...\n", "2MASS J05353130-0519533 05 35 31.31 ... I 2003yCat.2246....0C\n", " V* V2114 Ori 05 35 01.6680 ... O 2018yCat.1345....0G\n", "Length = 3262 rows\n" ] } ], "source": [ "c = coordinates.SkyCoord(\"05h35m17.3s -05d23m28s\", frame='icrs')\n", "r = 5 * u.arcminute\n", "\n", "result_table = Simbad.query_region(c, radius=r)\n", "result_table.pprint(show_unit=True, max_width=80, max_lines=5)" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "### VizieR" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [], "source": [ "from astroquery.vizier import Vizier" ] }, { "cell_type": "code", "execution_count": 9, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "{'J/ApJ/706/83': 'Embedded YSO candidates in W51 (Kang+, 2009)', 'J/ApJS/191/232': 'CO survey of W51 molecular cloud (Bieging+, 2010)'}\n" ] } ], "source": [ "catalog_list = Vizier.find_catalogs('Kang W51')\n", "\n", "print({k:v.description for k,v in catalog_list.items()})" ] }, { "cell_type": "code", "execution_count": 10, "metadata": {}, "outputs": [], "source": [ "result = Vizier.query_object(\"Sirius\")" ] }, { "cell_type": "code", "execution_count": 11, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "TableList with 311 tables:\n", "\t'0:METAobj' with 5 column(s) and 6 row(s) \n", "\t'1:ReadMeObj' with 5 column(s) and 6 row(s) \n", "\t'2:I/34/greenw2a' with 16 column(s) and 1 row(s) \n", "\t'3:I/40/catalog' with 11 column(s) and 1 row(s) \n", "\t'4:I/80/n30' with 13 column(s) and 1 row(s) \n", "\t'5:I/82/catalog' with 11 column(s) and 1 row(s) \n", "\t'6:I/87B/catalog' with 10 column(s) and 1 row(s) \n", "\t'7:I/98A/catalog' with 14 column(s) and 1 row(s) \n", "\t'8:I/98A/remarks' with 6 column(s) and 1 row(s) \n", "\t'9:I/100A/w10' with 9 column(s) and 1 row(s) \n", "\t'10:I/100A/w25' with 9 column(s) and 1 row(s) \n", "\t'11:I/100A/w50' with 9 column(s) and 5 row(s) \n", "\t'12:I/113A/catalog' with 10 column(s) and 1 row(s) \n", "\t'13:I/131A/sao' with 11 column(s) and 1 row(s) \n", "\t'14:I/143/fk4_1950' with 15 column(s) and 1 row(s) \n", "\t'15:I/149A/catalog' with 6 column(s) and 1 row(s) \n", "\t'16:I/193/ppm2' with 12 column(s) and 1 row(s) \n", "\t'17:I/196/main' with 14 column(s) and 1 row(s) \n", "\t'18:I/196/annex1' with 10 column(s) and 4 row(s) \n", "\t'19:I/197A/tic' with 10 column(s) and 1 row(s) \n", "\t'20:I/238A/picat' with 15 column(s) and 1 row(s) \n", "\t'21:I/239/hip_main' with 14 column(s) and 1 row(s) \n", "\t'22:I/239/tyc_main' with 11 column(s) and 1 row(s) \n", "\t'23:I/246/act' with 8 column(s) and 1 row(s) \n", "\t'24:I/248/catalog' with 9 column(s) and 1 row(s) \n", "\t'25:I/252/out' with 8 column(s) and 1 row(s) \n", "\t'26:I/254/out' with 10 column(s) and 2 row(s) \n", "\t'27:I/256/fk5u' with 9 column(s) and 4 row(s) \n", "\t'28:I/259/suppl_1' with 10 column(s) and 1 row(s) \n", "\t'29:I/260/ccdmhipn' with 11 column(s) and 4 row(s) \n", "\t'30:I/270/cpirss01' with 8 column(s) and 1 row(s) \n", "\t'31:I/274/ccdm' with 13 column(s) and 4 row(s) \n", "\t'32:I/275/ac2002' with 9 column(s) and 2 row(s) \n", "\t'33:I/276/supplem' with 15 column(s) and 1 row(s) \n", "\t'34:I/279/catalog' with 11 column(s) and 1 row(s) \n", "\t'35:I/280B/ascc' with 12 column(s) and 1 row(s) \n", "\t'36:I/284/out' with 14 column(s) and 1 row(s) \n", "\t'37:I/294A/ucac2bss' with 12 column(s) and 1 row(s) \n", "\t'38:I/297/out' with 19 column(s) and 8 row(s) \n", "\t'39:I/305/out' with 11 column(s) and 15 row(s) \n", "\t'40:I/311/hip2' with 13 column(s) and 1 row(s) \n", "\t'41:I/312/sample' with 13 column(s) and 3 row(s) \n", "\t'42:I/317/sample' with 13 column(s) and 3 row(s) \n", "\t'43:I/322A/out' with 24 column(s) and 3 row(s) \n", "\t'44:I/324/igsl3' with 18 column(s) and 7 row(s) \n", "\t'45:I/328/table1' with 17 column(s) and 1 row(s) \n", "\t'46:I/334/w1j00sta' with 17 column(s) and 1 row(s) \n", "\t'47:I/334/w2j00sta' with 27 column(s) and 1 row(s) \n", "\t'48:I/337/gaia' with 14 column(s) and 36 row(s) \n", "\t'49:I/339/hsoy' with 18 column(s) and 1 row(s) \n", "\t'50:I/343/gps1' with 39 column(s) and 3 row(s) \n", "\t'51:I/345/gaia2' with 32 column(s) and 50 row(s) \n", "\t'52:I/347/gaia2dis' with 9 column(s) and 50 row(s) \n", "\t'53:I/348/catalog' with 35 column(s) and 1 row(s) \n", "\t'54:II/2B/catalog' with 16 column(s) and 1 row(s) \n", "\t'55:II/5A/data' with 10 column(s) and 1 row(s) \n", "\t'56:II/6/catalog' with 31 column(s) and 1 row(s) \n", "\t'57:II/7A/catalog' with 17 column(s) and 5 row(s) \n", "\t'58:II/8/mean' with 12 column(s) and 1 row(s) \n", "\t'59:II/27/means' with 9 column(s) and 1 row(s) \n", "\t'60:II/38/ph18' with 20 column(s) and 1 row(s) \n", "\t'61:II/38/ph28' with 12 column(s) and 1 row(s) \n", "\t'62:II/42/data' with 21 column(s) and 1 row(s) \n", "\t'63:II/43/data' with 21 column(s) and 1 row(s) \n", "\t'64:II/50/ubv' with 18 column(s) and 1 row(s) \n", "\t'65:II/53/catalog' with 22 column(s) and 1 row(s) \n", "\t'66:II/59B/catalog' with 20 column(s) and 1 row(s) \n", "\t'67:II/62/catalog' with 14 column(s) and 1 row(s) \n", "\t'68:II/84/catalog' with 23 column(s) and 1 row(s) \n", "\t'69:II/94/main' with 11 column(s) and 1 row(s) \n", "\t'70:II/122B/merged' with 12 column(s) and 14 row(s) \n", "\t'71:II/125/main' with 13 column(s) and 1 row(s) \n", "\t'72:II/126/sources' with 9 column(s) and 3 row(s) \n", "\t'73:II/134/data' with 11 column(s) and 8 row(s) \n", "\t'74:II/167/catalog' with 8 column(s) and 3 row(s) \n", "\t'75:II/168/ubvmeans' with 15 column(s) and 2 row(s) \n", "\t'76:II/169/main' with 14 column(s) and 1 row(s) \n", "\t'77:II/215/catalog' with 18 column(s) and 2 row(s) \n", "\t'78:II/224/cadars' with 12 column(s) and 24 row(s) \n", "\t'79:II/225/catalog' with 14 column(s) and 50 row(s) \n", "\t'80:II/225/names' with 5 column(s) and 11 row(s) \n", "\t'81:II/225/psc' with 8 column(s) and 1 row(s) \n", "\t'82:II/235/deltam' with 11 column(s) and 4 row(s) \n", "\t'83:II/237/colors' with 14 column(s) and 1 row(s) \n", "\t'84:II/246/out' with 15 column(s) and 7 row(s) \n", "\t'85:II/275/fsr' with 15 column(s) and 1 row(s) \n", "\t'86:II/275/assoc' with 14 column(s) and 9 row(s) \n", "\t'87:II/297/irc' with 13 column(s) and 1 row(s) \n", "\t'88:II/298/fis' with 15 column(s) and 1 row(s) \n", "\t'89:II/311/wise' with 22 column(s) and 19 row(s) \n", "\t'90:II/328/allwise' with 28 column(s) and 27 row(s) \n", "\t'91:II/336/apass9' with 20 column(s) and 1 row(s) \n", "\t'92:II/338/catalog' with 23 column(s) and 1 row(s) \n", "\t'93:II/345/jmdc' with 16 column(s) and 5 row(s) \n", "\t'94:II/346/jsdc_v2' with 30 column(s) and 1 row(s) \n", "\t'95:II/349/ps1' with 35 column(s) and 50 row(s) \n", "\t'96:II/354/hipext' with 12 column(s) and 1 row(s) \n", "\t'97:II/355/ugriz-2' with 21 column(s) and 1 row(s) \n", "\t'98:III/4/catalog' with 22 column(s) and 2 row(s) \n", "\t'99:III/18B/mkclass' with 12 column(s) and 9 row(s) \n", "\t'100:III/21/gcrv' with 13 column(s) and 1 row(s) \n", "\t'101:III/29/catalog' with 17 column(s) and 1 row(s) \n", "\t'102:III/39A/catalog' with 17 column(s) and 1 row(s) \n", "\t'103:III/42/catalog' with 12 column(s) and 1 row(s) \n", "\t'104:III/45/spectra' with 9 column(s) and 2 row(s) \n", "\t'105:III/47B/catalog' with 18 column(s) and 1 row(s) \n", "\t'106:III/48B/catalog' with 11 column(s) and 4 row(s) \n", "\t'107:III/53/catalog' with 10 column(s) and 1 row(s) \n", "\t'108:III/58/catalog' with 13 column(s) and 6 row(s) \n", "\t'109:III/77/stars' with 12 column(s) and 1 row(s) \n", "\t'110:III/78/mkext' with 11 column(s) and 4 row(s) \n", "\t'111:III/119/lttstars' with 17 column(s) and 1 row(s) \n", "\t'112:III/121/catalog' with 17 column(s) and 50 row(s) \n", "\t'113:III/126/stars' with 6 column(s) and 1 row(s) \n", "\t'114:III/126/part1' with 11 column(s) and 1 row(s) \n", "\t'115:III/126/part2' with 11 column(s) and 1 row(s) \n", "\t'116:III/126/part3' with 11 column(s) and 2 row(s) \n", "\t'117:III/133/vol4' with 17 column(s) and 1 row(s) \n", "\t'118:III/135A/catalog' with 17 column(s) and 1 row(s) \n", "\t'119:III/148A/table1' with 8 column(s) and 4 row(s) \n", "\t'120:III/148A/table3' with 10 column(s) and 2 row(s) \n", "\t'121:III/184/catalog' with 15 column(s) and 2 row(s) \n", "\t'122:III/190B/web' with 16 column(s) and 1 row(s) \n", "\t'123:III/193/catalog' with 13 column(s) and 1 row(s) \n", "\t'124:III/197/lrs' with 14 column(s) and 1 row(s) \n", "\t'125:III/201/stars' with 8 column(s) and 1 row(s) \n", "\t'126:III/202/catalog' with 7 column(s) and 1 row(s) \n", "\t'127:III/213/catalog' with 12 column(s) and 1 row(s) \n", "\t'128:III/223/mk12' with 9 column(s) and 2 row(s) \n", "\t'129:III/244/catalog' with 11 column(s) and 16 row(s) \n", "\t'130:III/244/mean' with 8 column(s) and 1 row(s) \n", "\t'131:III/244/standard' with 6 column(s) and 1 row(s) \n", "\t'132:III/249/catalog' with 14 column(s) and 7 row(s) \n", "\t'133:III/252/table8' with 12 column(s) and 1 row(s) \n", "\t'134:III/254/crvad2' with 12 column(s) and 1 row(s) \n", "\t'135:III/260/catalog' with 18 column(s) and 1 row(s) \n", "\t'136:IV/22/index' with 10 column(s) and 1 row(s) \n", "\t'137:IV/25/tyc2_hd' with 14 column(s) and 1 row(s) \n", "\t'138:IV/27A/catalog' with 13 column(s) and 1 row(s) \n", "\t'139:V/14/catalog' with 16 column(s) and 1 row(s) \n", "\t'140:V/15/catalog' with 12 column(s) and 1 row(s) \n", "\t'141:V/24/cstar' with 12 column(s) and 1 row(s) \n", "\t'142:V/32A/catalog' with 14 column(s) and 2 row(s) \n", "\t'143:V/41/catalog' with 20 column(s) and 1 row(s) \n", "\t'144:V/50/catalog' with 11 column(s) and 1 row(s) \n", "\t'145:V/51/disco' with 10 column(s) and 10 row(s) \n", "\t'146:V/53A/catalog' with 13 column(s) and 1 row(s) \n", "\t'147:V/68A/table1' with 10 column(s) and 1 row(s) \n", "\t'148:V/70A/catalog' with 12 column(s) and 2 row(s) \n", "\t'149:V/85A/catalog' with 13 column(s) and 2 row(s) \n", "\t'150:V/98/msx' with 11 column(s) and 1 row(s) \n", "\t'151:V/101/catalog' with 15 column(s) and 2 row(s) \n", "\t'152:V/135A/catalog' with 18 column(s) and 1 row(s) \n", "\t'153:V/137D/XHIP' with 15 column(s) and 1 row(s) \n", "\t'154:V/145/sky2kv5' with 13 column(s) and 1 row(s) \n", "\t'155:VI/32/data1' with 14 column(s) and 1 row(s) \n", "\t'156:VI/110/inescat' with 7 column(s) and 50 row(s) \n", "\t'157:VI/111/isolog' with 7 column(s) and 24 row(s) \n", "\t'158:VI/129/fuse' with 10 column(s) and 4 row(s) \n", "\t'159:VIII/65/nvss' with 12 column(s) and 1 row(s) \n", "\t'160:VIII/99/stars' with 11 column(s) and 1 row(s) \n", "\t'161:IX/6/data' with 15 column(s) and 1 row(s) \n", "\t'162:IX/8/catalog' with 10 column(s) and 2 row(s) \n", "\t'163:IX/10A/1rxs' with 11 column(s) and 1 row(s) \n", "\t'164:IX/10A/1rxs_cor' with 10 column(s) and 1 row(s) \n", "\t'165:IX/10A/cor_iras' with 6 column(s) and 1 row(s) \n", "\t'166:IX/10A/cor_nvs' with 6 column(s) and 1 row(s) \n", "\t'167:IX/10A/cor_pri' with 6 column(s) and 13 row(s) \n", "\t'168:IX/10A/cor_hst' with 6 column(s) and 1 row(s) \n", "\t'169:IX/10A/cor_wfc' with 6 column(s) and 1 row(s) \n", "\t'170:IX/10A/cor_ros' with 6 column(s) and 3 row(s) \n", "\t'171:IX/13/2e' with 10 column(s) and 5 row(s) \n", "\t'172:IX/24/hrifield' with 10 column(s) and 2 row(s) \n", "\t'173:IX/24/hrisrc' with 11 column(s) and 1 row(s) \n", "\t'174:IX/25/ipcfield' with 8 column(s) and 1 row(s) \n", "\t'175:IX/25/ipcihut' with 9 column(s) and 1 row(s) \n", "\t'176:IX/28A/hricat' with 11 column(s) and 33 row(s) \n", "\t'177:IX/28A/seq' with 8 column(s) and 1 row(s) \n", "\t'178:IX/35/survey' with 10 column(s) and 1 row(s) \n", "\t'179:IX/35/faint' with 9 column(s) and 1 row(s) \n", "\t'180:B/denis/denis' with 15 column(s) and 50 row(s) \n", "\t'181:B/hst/obscore' with 12 column(s) and 50 row(s) \n", "\t'182:B/hst/hstlog' with 9 column(s) and 50 row(s) \n", "\t'183:B/cfht/obscore' with 11 column(s) and 50 row(s) \n", "\t'184:B/cfht/cfht' with 8 column(s) and 50 row(s) \n", "\t'185:B/chandra/chandra' with 11 column(s) and 5 row(s) \n", "\t'186:B/eso/eso_arc' with 7 column(s) and 50 row(s) \n", "\t'187:B/sb9/main' with 13 column(s) and 1 row(s) \n", "\t'188:B/mk/mktypes' with 11 column(s) and 18 row(s) \n", "\t'189:B/gcvs/nsv_cat' with 10 column(s) and 2 row(s) \n", "\t'190:B/wds/wds' with 16 column(s) and 6 row(s) \n", "\t'191:B/vsx/vsx' with 19 column(s) and 2 row(s) \n", "\t'192:B/pastel/pastel' with 13 column(s) and 23 row(s) \n", "\t'193:B/wd/catalog' with 14 column(s) and 1 row(s) \n", "\t'194:B/assocdata/obscore' with 13 column(s) and 1 row(s) \n", "\t'195:B/gemini/obscore' with 10 column(s) and 50 row(s) \n", "\t'196:J/ApJ/351/492/st_uma_1' with 14 column(s) and 1 row(s) \n", "\t'197:J/ApJ/508/397/stars' with 13 column(s) and 2 row(s) \n", "\t'198:J/ApJ/571/512/table1' with 13 column(s) and 1 row(s) \n", "\t'199:J/ApJ/582/1011/table2' with 12 column(s) and 1 row(s) \n", "\t'200:J/ApJ/616/562/vsini' with 12 column(s) and 1 row(s) \n", "\t'201:J/ApJ/620/1010/table1' with 14 column(s) and 1 row(s) \n", "\t'202:J/ApJ/629/507/Pecc' with 10 column(s) and 1 row(s) \n", "\t'203:J/ApJ/652/1554/table4' with 7 column(s) and 1 row(s) \n", "\t'204:J/ApJ/653/675/table1' with 15 column(s) and 1 row(s) \n", "\t'205:J/ApJ/660/1556/table4' with 10 column(s) and 1 row(s) \n", "\t'206:J/ApJ/700/1299/table2' with 15 column(s) and 2 row(s) \n", "\t'207:J/ApJ/734/13/table1' with 13 column(s) and 1 row(s) \n", "\t'208:J/ApJ/737/45/table1' with 8 column(s) and 1 row(s) \n", "\t'209:J/ApJ/743/138/table5' with 15 column(s) and 1 row(s) \n", "\t'210:J/ApJ/753/156/table4' with 16 column(s) and 2 row(s) \n", "\t'211:J/ApJ/771/40/table7' with 24 column(s) and 1 row(s) \n", "\t'212:J/ApJ/804/146/table5' with 16 column(s) and 1 row(s) \n", "\t'213:J/ApJ/808/194/table2' with 14 column(s) and 1 row(s) \n", "\t'214:J/ApJ/808/194/table3' with 14 column(s) and 1 row(s) \n", "\t'215:J/ApJ/826/171/table3' with 11 column(s) and 1 row(s) \n", "\t'216:J/ApJ/848/11/table1' with 20 column(s) and 1 row(s) \n", "\t'217:J/ApJS/94/127/table1' with 14 column(s) and 6 row(s) \n", "\t'218:J/ApJS/111/445/table1' with 7 column(s) and 1 row(s) \n", "\t'219:J/ApJS/112/557/table1' with 11 column(s) and 1 row(s) \n", "\t'220:J/ApJS/119/207/table1' with 14 column(s) and 1 row(s) \n", "\t'221:J/ApJS/119/207/table6' with 11 column(s) and 1 row(s) \n", "\t'222:J/ApJS/150/343/table2' with 9 column(s) and 2 row(s) \n", "\t'223:J/ApJS/151/299/table5' with 7 column(s) and 1 row(s) \n", "\t'224:J/ApJS/154/673/DIRBE' with 17 column(s) and 1 row(s) \n", "\t'225:J/ApJS/154/673/table5' with 7 column(s) and 1 row(s) \n", "\t'226:J/ApJS/184/138/table3' with 12 column(s) and 1 row(s) \n", "\t'227:J/ApJS/190/203/table3' with 19 column(s) and 1 row(s) \n", "\t'228:J/ApJS/199/8/table1' with 17 column(s) and 12 row(s) \n", "\t'229:J/ApJS/199/8/table2' with 18 column(s) and 2 row(s) \n", "\t'230:J/A+A/281/161/radiostars' with 14 column(s) and 1 row(s) \n", "\t'231:J/A+A/281/161/table9' with 11 column(s) and 1 row(s) \n", "\t'232:J/A+A/316/147/table1' with 8 column(s) and 1 row(s) \n", "\t'233:J/A+A/348/897/tablea6' with 13 column(s) and 1 row(s) \n", "\t'234:J/A+A/352/555/table1' with 12 column(s) and 1 row(s) \n", "\t'235:J/A+A/381/105/table4' with 11 column(s) and 1 row(s) \n", "\t'236:J/A+A/381/446/table2a' with 13 column(s) and 1 row(s) \n", "\t'237:J/A+A/386/492/charm' with 12 column(s) and 1 row(s) \n", "\t'238:J/A+A/390/1033/table1' with 7 column(s) and 1 row(s) \n", "\t'239:J/A+A/393/897/table9' with 8 column(s) and 1 row(s) \n", "\t'240:J/A+A/407/631/tablea1' with 11 column(s) and 2 row(s) \n", "\t'241:J/A+A/420/183/table2' with 12 column(s) and 1 row(s) \n", "\t'242:J/A+A/420/183/table3' with 7 column(s) and 1 row(s) \n", "\t'243:J/A+A/420/507/MWDCat' with 15 column(s) and 1 row(s) \n", "\t'244:J/A+A/431/773/charm2' with 13 column(s) and 8 row(s) \n", "\t'245:J/A+A/434/1201/table4' with 11 column(s) and 1 row(s) \n", "\t'246:J/A+A/475/677/stars' with 17 column(s) and 1 row(s) \n", "\t'247:J/A+A/489/1271/table2' with 10 column(s) and 2 row(s) \n", "\t'248:J/A+A/510/A54/table1' with 18 column(s) and 1 row(s) \n", "\t'249:J/A+A/531/A143/table1' with 8 column(s) and 1 row(s) \n", "\t'250:J/A+A/533/A107/stars' with 21 column(s) and 1 row(s) \n", "\t'251:J/A+A/541/A52/table1' with 22 column(s) and 1 row(s) \n", "\t'252:J/A+A/546/A61/tablea1' with 18 column(s) and 1 row(s) \n", "\t'253:J/A+A/546/A69/table1' with 20 column(s) and 1 row(s) \n", "\t'254:J/A+A/553/A95/table5' with 7 column(s) and 1 row(s) \n", "\t'255:J/A+A/574/A6/systems' with 17 column(s) and 1 row(s) \n", "\t'256:J/A+A/574/A6/table3' with 16 column(s) and 1 row(s) \n", "\t'257:J/A+A/575/A35/table3' with 21 column(s) and 2 row(s) \n", "\t'258:J/A+A/580/A23/catalog' with 22 column(s) and 1 row(s) \n", "\t'259:J/A+A/588/A103/cat2rxs' with 35 column(s) and 1 row(s) \n", "\t'260:J/A+A/589/A83/table2' with 19 column(s) and 1 row(s) \n", "\t'261:J/A+A/594/A116/nhi_hpx' with 6 column(s) and 1 row(s) \n", "\t'262:J/A+A/596/A49/fuvvar' with 8 column(s) and 2 row(s) \n", "\t'263:J/A+A/598/A78/table3' with 18 column(s) and 1 row(s) \n", "\t'264:J/A+AS/101/551/table1' with 13 column(s) and 1 row(s) \n", "\t'265:J/A+AS/114/465/table2' with 9 column(s) and 1 row(s) \n", "\t'266:J/A+AS/114/465/table4' with 8 column(s) and 1 row(s) \n", "\t'267:J/A+AS/119/547/table5' with 8 column(s) and 1 row(s) \n", "\t'268:J/A+AS/119/547/table7' with 8 column(s) and 1 row(s) \n", "\t'269:J/A+AS/135/503/table8' with 9 column(s) and 1 row(s) \n", "\t'270:J/AJ/107/751/table2' with 8 column(s) and 1 row(s) \n", "\t'271:J/AJ/115/2587/table1' with 9 column(s) and 5 row(s) \n", "\t'272:J/AJ/115/2587/table2' with 10 column(s) and 5 row(s) \n", "\t'273:J/AJ/121/2189/table1' with 8 column(s) and 2 row(s) \n", "\t'274:J/AJ/126/2048/table1' with 13 column(s) and 1 row(s) \n", "\t'275:J/AJ/127/477/table1' with 17 column(s) and 1 row(s) \n", "\t'276:J/AJ/135/1225/localWD' with 16 column(s) and 1 row(s) \n", "\t'277:J/AJ/138/1681/WD20pc' with 17 column(s) and 1 row(s) \n", "\t'278:J/AJ/141/129/table6' with 14 column(s) and 3 row(s) \n", "\t'279:J/AJ/143/28/iuestars' with 21 column(s) and 1 row(s) \n", "\t'280:J/AJ/144/62/table1' with 15 column(s) and 1 row(s) \n", "\t'281:J/AJ/144/64/table2' with 18 column(s) and 1 row(s) \n", "\t'282:J/AJ/146/68/stars' with 9 column(s) and 1 row(s) \n", "\t'283:J/AJ/147/129/table1' with 17 column(s) and 1 row(s) \n", "\t'284:J/AJ/147/129/table3' with 10 column(s) and 1 row(s) \n", "\t'285:J/AJ/148/3/table1' with 7 column(s) and 1 row(s) \n", "\t'286:J/AJ/153/95/table3' with 17 column(s) and 1 row(s) \n", "\t'287:J/AJ/154/115/table2' with 8 column(s) and 1 row(s) \n", "\t'288:J/PASP/109/998/table1' with 7 column(s) and 1 row(s) \n", "\t'289:J/PASP/119/994/table5' with 16 column(s) and 1 row(s) \n", "\t'290:J/PASP/120/1128/catalog' with 15 column(s) and 1 row(s) \n", "\t'291:J/PASP/122/885/table1' with 15 column(s) and 1 row(s) \n", "\t'292:J/PASP/126/469/polar' with 11 column(s) and 1 row(s) \n", "\t'293:J/PASP/129/E4501/table1' with 10 column(s) and 1 row(s) \n", "\t'294:J/MNRAS/260/77/table1' with 8 column(s) and 4 row(s) \n", "\t'295:J/MNRAS/274/1165/catalog' with 11 column(s) and 1 row(s) \n", "\t'296:J/MNRAS/389/869/table2' with 14 column(s) and 1 row(s) \n", "\t'297:J/MNRAS/394/1338/tablea2' with 12 column(s) and 1 row(s) \n", "\t'298:J/MNRAS/403/1089/table4' with 10 column(s) and 2 row(s) \n", "\t'299:J/MNRAS/435/2077/catalog' with 26 column(s) and 1 row(s) \n", "\t'300:J/MNRAS/454/2863/table1' with 28 column(s) and 1 row(s) \n", "\t'301:J/MNRAS/454/3267/table1' with 16 column(s) and 2 row(s) \n", "\t'302:J/MNRAS/459/1415/table3' with 12 column(s) and 1 row(s) \n", "\t'303:J/MNRAS/462/2295/table1' with 14 column(s) and 1 row(s) \n", "\t'304:J/MNRAS/480/2953/cpstars' with 90 column(s) and 1 row(s) \n", "\t'305:J/AZh/72/495/table5' with 10 column(s) and 2 row(s) \n", "\t'306:J/AZh/83/821/osaca' with 13 column(s) and 1 row(s) \n", "\t'307:J/PAZh/31/437/table' with 11 column(s) and 1 row(s) \n", "\t'308:J/BaltA/10/481/table1' with 10 column(s) and 1 row(s) \n", "\t'309:J/other/JAVSO/42.443/ugriz' with 21 column(s) and 1 row(s) \n", "\t'310:J/other/JHA/47.294/margha01' with 9 column(s) and 2 row(s) \n" ] } ], "source": [ "print(result)" ] }, { "cell_type": "code", "execution_count": 12, "metadata": {}, "outputs": [ { "name": "stderr", "output_type": "stream", "text": [ "/usr/local/lib/python3.7/site-packages/astroquery/vizier/core.py:793: UserWarning: xry : No such keyword\n", " warnings.warn(\"{val} : No such keyword\".format(val=val))\n" ] } ], "source": [ "v = Vizier(columns=['_RAJ2000', '_DEJ2000','B-V', 'Vmag', 'Plx'],\n", " column_filters={\"Vmag\":\">10\"}, keywords=[\"optical\", \"xry\"])\n", "\n", "result = v.query_object(\"HD 226868\", catalog=[\"NOMAD\", \"UCAC\"])" ] }, { "cell_type": "code", "execution_count": 13, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "TableList with 4 tables:\n", "\t'0:I/297/out' with 3 column(s) and 50 row(s) \n", "\t'1:I/289/out' with 3 column(s) and 18 row(s) \n", "\t'2:I/322A/out' with 3 column(s) and 10 row(s) \n", "\t'3:I/340/ucac5' with 3 column(s) and 26 row(s) \n" ] } ], "source": [ "print(result)" ] }, { "cell_type": "code", "execution_count": 14, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " _RAJ2000 _DEJ2000 Vmag \n", " deg deg mag \n", "------------- ------------- ------\n", "299.572418900 35.194234200 15.986\n", "299.580291200 35.176888900 13.274\n", "299.582571200 35.185225300 14.863\n", "299.594171800 35.179994800 14.690\n", "299.601402100 35.198107800 14.644\n", "299.617668600 35.186998700 14.394\n", "299.561497700 35.201692800 15.687\n", "299.570216500 35.225663400 14.878\n", "299.601080600 35.233337800 13.170\n", "299.617995000 35.205863700 13.946\n" ] } ], "source": [ "print(result['I/322A/out'])" ] }, { "cell_type": "code", "execution_count": 15, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " GRSMC GLON GLAT VLSR DelV ... alpha Note RD09 _RA.icrs _DE.icrs\n", " deg deg km / s km / s ... deg deg \n", "------------- ------ ------ ------ ------ ... ------ ---- ---- -------- --------\n", "G049.49-00.41 49.49 -0.41 56.90 9.12 ... 0.73 i RD09 290.9536 14.4992\n", "G049.39-00.26 49.39 -0.26 50.94 3.51 ... 0.16 i RD09 290.7682 14.4819\n", "G049.44-00.06 49.44 -0.06 62.00 3.67 ... 0.17 i RD09 290.6104 14.6203\n", "G049.04-00.31 49.04 -0.31 66.25 2.74 ... 0.14 i RD09 290.6433 14.1497\n", "G049.74-00.56 49.74 -0.56 67.95 3.69 ... 0.56 i RD09 291.2124 14.6484\n", "G050.39-00.41 50.39 -0.41 41.17 3.92 ... 0.88 i RD09 291.3948 15.2917\n", "G050.24-00.61 50.24 -0.61 41.17 3.91 ... 0.55 i RD09 291.5033 15.0647\n", "G050.94-00.61 50.94 -0.61 40.32 5.81 ... 3.03 i RD09 291.8488 15.6804\n", "G049.99-00.16 49.99 -0.16 46.27 2.69 ... 0.66 i RD09 290.9703 15.0579\n", "G049.44-00.06 49.44 -0.06 46.27 3.90 ... 0.90 i RD09 290.6104 14.6203\n", "G049.54-00.01 49.54 -0.01 56.05 3.38 ... 0.45 i RD09 290.6136 14.7321\n", "G049.74-00.01 49.74 -0.01 48.39 2.68 ... 0.76 i RD09 290.7112 14.9085\n", "G049.54-00.91 49.54 -0.91 43.29 4.51 ... 0.60 i RD09 291.4326 14.3063\n", "G049.04-00.46 49.04 -0.46 58.60 2.71 ... 0.41 i RD09 290.7796 14.0789\n", "G049.09-00.06 49.09 -0.06 46.69 2.22 ... 0.42 i RD09 290.4401 14.3116\n", "G050.84-00.11 50.84 -0.11 50.52 4.43 ... 1.37 i RD09 291.3424 15.8302\n", "G050.89-00.11 50.89 -0.11 59.45 2.71 ... 0.92 i RD09 291.3670 15.8742\n", "G050.44-00.41 50.44 -0.41 64.12 3.27 ... 0.62 i RD09 291.4194 15.3357\n", "G050.84-00.76 50.84 -0.76 61.15 6.31 ... 2.94 i RD09 291.9362 15.5210\n", "G050.29-00.46 50.29 -0.46 14.81 2.20 ... 0.47 i RD09 291.3912 15.1800\n" ] } ], "source": [ "result = Vizier.query_constraints(catalog='J/ApJ/723/492/table1',\n", " GLON='>49.0 & <51.0', GLAT='<0')\n", "\n", "result[result.keys()[0]].pprint()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "#### Conesearch" ] }, { "cell_type": "code", "execution_count": 16, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "'http://gsss.stsci.edu/webservices/vo/ConeSearch.aspx?CAT=GSC23&'" ] }, "execution_count": 16, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from astropy.coordinates import SkyCoord\n", "\n", "from astroquery.vo_conesearch import ConeSearch\n", "\n", "ConeSearch.URL" ] }, { "cell_type": "code", "execution_count": 17, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " objID gsc2ID gsc1ID ... multipleFlag compassGSC2id Mag \n", " ... mag \n", "-------------- ---------------- ------ ... ------------ ------------- -------\n", "23323175812944 00424433+4116085 ... 0 6453800072293 9.453\n", "23323175812948 00424403+4116069 ... 0 6453800072297 9.321\n", "23323175812933 00424455+4116103 ... 0 6453800072282 10.773\n", "23323175812939 00424464+4116092 ... 0 6453800072288 9.299\n", "23323175812930 00424403+4116108 ... 0 6453800072279 11.507\n", "23323175812931 00424464+4116106 ... 0 6453800072280 9.399\n", "23323175812973 00424446+4116016 ... 0 6453800072322 12.07\n", "23323175812966 00424398+4116028 ... 0 6453800072315 12.136\n", "23323175812979 00424420+4116009 ... 0 6453800072328 10.065\n", "23323175812958 00424377+4116045 ... 0 6453800072307 12.446\n", " ... ... ... ... ... ... ...\n", " 1330012229027 N330012229027 ... 0 6453800029027 20.3122\n", " 1330012247547 N330012247547 ... 0 6453800047547 21.5449\n", " 1330012244072 N330012244072 ... 0 6453800044072 20.9598\n", " 1330012248107 N330012248107 ... 0 6453800048107 21.6947\n", " 133001227000 N33001227000 ... 0 6453800007000 20.1382\n", " 1330012244001 N330012244001 ... 0 6453800044001 21.8968\n", " 1330012228861 N330012228861 ... 0 6453800028861 20.3572\n", " 1330012212014 N330012212014 ... 0 6453800012014 16.5079\n", " 1330012231849 N330012231849 ... 0 6453800031849 20.2869\n", " 1330012210212 N330012210212 ... 0 6453800010212 20.2767\n", "Length = 4028 rows\n" ] } ], "source": [ "c = SkyCoord.from_name('M31')\n", "\n", "result = ConeSearch.query_region(c, '0.1 deg')\n", "\n", "print(result)" ] }, { "cell_type": "code", "execution_count": 20, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "['Guide Star Catalog 2.3 Cone Search 1',\n", " 'SDSS DR7 - Sloan Digital Sky Survey Data Release 7 1',\n", " 'SDSS DR7 - Sloan Digital Sky Survey Data Release 7 2',\n", " 'SDSS DR7 - Sloan Digital Sky Survey Data Release 7 3',\n", " 'SDSS DR7 - Sloan Digital Sky Survey Data Release 7 4',\n", " 'SDSS DR8 - Sloan Digital Sky Survey Data Release 8 1',\n", " 'SDSS DR8 - Sloan Digital Sky Survey Data Release 8 2',\n", " 'The HST Guide Star Catalog, Version 1.1 (Lasker+ 1992) 1',\n", " 'The HST Guide Star Catalog, Version 1.2 (Lasker+ 1996) 1',\n", " 'The HST Guide Star Catalog, Version GSC-ACT (Lasker+ 1996-99) 1',\n", " 'The USNO-A2.0 Catalogue (Monet+ 1998) 1',\n", " 'Two Micron All Sky Survey (2MASS) 1',\n", " 'Two Micron All Sky Survey (2MASS) 2']" ] }, "execution_count": 20, "metadata": {}, "output_type": "execute_result" } ], "source": [ "from astroquery.vo_conesearch import conesearch\n", "conesearch.list_catalogs()" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "#### TAP" ] }, { "cell_type": "code", "execution_count": 23, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Created TAP+ (v1.0.1) - Connection:\n", "\tHost: gea.esac.esa.int\n", "\tUse HTTPS: False\n", "\tPort: 80\n", "\tSSL Port: 443\n" ] } ], "source": [ "from astroquery.gaia import Gaia\n", "coord = SkyCoord(ra=280, dec=-60, unit=(u.degree, u.degree), frame='icrs')" ] }, { "cell_type": "code", "execution_count": 24, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ "Query finished.\n" ] } ], "source": [ "width = u.Quantity(0.1, u.deg)\n", "height = u.Quantity(0.1, u.deg)\n", "r = Gaia.query_object_async(coordinate=coord, width=width, height=height)" ] }, { "cell_type": "code", "execution_count": 25, "metadata": {}, "outputs": [ { "name": "stdout", "output_type": "stream", "text": [ " dist solution_id ... epoch_photometry_url\n", " ... \n", "--------------------- ------------------- ... --------------------\n", "0.0026034636994048854 1635721458409799680 ... --\n", "0.0038518741347606357 1635721458409799680 ... --\n", " 0.00454542650096783 1635721458409799680 ... --\n", " 0.005613919443965546 1635721458409799680 ... --\n", " 0.005846434715822121 1635721458409799680 ... --\n", " 0.006209042666371929 1635721458409799680 ... --\n", " 0.007469463683838576 1635721458409799680 ... --\n", " 0.008202004514524316 1635721458409799680 ... --\n", " 0.008338509690874027 1635721458409799680 ... --\n", " 0.008406677772258921 1635721458409799680 ... --\n", " ... ... ... ...\n", " 0.049718018073992835 1635721458409799680 ... --\n", " 0.04977869666747251 1635721458409799680 ... --\n", " 0.05006096698512638 1635721458409799680 ... --\n", " 0.05038566478030134 1635721458409799680 ... --\n", " 0.050827895451955894 1635721458409799680 ... --\n", " 0.050860907684754444 1635721458409799680 ... --\n", " 0.051038347209386326 1635721458409799680 ... --\n", " 0.05121063325107872 1635721458409799680 ... --\n", " 0.051957226883925664 1635721458409799680 ... --\n", " 0.05320916763883812 1635721458409799680 ... --\n", "Length = 176 rows\n" ] } ], "source": [ "r.pprint()" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Python 3", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.7.1" } }, "nbformat": 4, "nbformat_minor": 2 }