Skip to content

Commit

Permalink
Cross-match TYC2 supplements to SAO
Browse files Browse the repository at this point in the history
  • Loading branch information
ajtribick committed Sep 26, 2020
1 parent 1bcb2fe commit 9a39af1
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 4 deletions.
4 changes: 3 additions & 1 deletion download_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,9 @@ def download_sao_xmatch() -> None:

cross_matches = [
('vizier:I/131A/sao', 'vizier:I/311/hip2', 'sao_hip_xmatch.csv'),
('vizier:I/131A/sao', 'vizier:I/259/tyc2', 'sao_tyc2_xmatch.csv')
('vizier:I/131A/sao', 'vizier:I/259/tyc2', 'sao_tyc2_xmatch.csv'),
('vizier:I/131A/sao', 'vizier:I/259/suppl_1', 'sao_tyc2_suppl1_xmatch.csv'),
('vizier:I/131A/sao', 'vizier:I/259/suppl_2', 'sao_tyc2_suppl2_xmatch.csv'),
]

for cat1, cat2, filename in cross_matches:
Expand Down
11 changes: 8 additions & 3 deletions parse_tyc.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,9 +203,14 @@ def load_tyc_teff() -> Table:
def load_sao() -> Table:
"""Load the SAO-TYC2 cross match."""
print('Loading SAO-TYC2 cross match')
data = io_ascii.read(os.path.join('xmatch', 'sao_tyc2_xmatch.csv'),
include_names=['SAO', 'TYC1', 'TYC2', 'TYC3', 'angDist', 'delFlag'],
format='csv')
xmatch_files = ['sao_tyc2_xmatch.csv',
'sao_tyc2_suppl1_xmatch.csv',
'sao_tyc2_suppl2_xmatch.csv']
data = vstack([io_ascii.read(os.path.join('xmatch', f),
include_names=['SAO', 'TYC1', 'TYC2', 'TYC3', 'angDist', 'delFlag'],
format='csv',
converters={'delFlag': [io_ascii.convert_numpy(np.str)]})
for f in xmatch_files], join_type='exact')

data = data[data['delFlag'].mask]
data.remove_column('delFlag')
Expand Down

0 comments on commit 9a39af1

Please sign in to comment.