Skip to content

Commit

Permalink
fix: skip empty msms hit data
Browse files Browse the repository at this point in the history
  • Loading branch information
tharwood3 committed Mar 6, 2024
1 parent 677821f commit 6a49640
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions metatlas/io/metatlas_get_data_helper_fun.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
from metatlas.datastructures import metatlas_objects as metob
from metatlas.io import h5_query as h5q
from metatlas.io import write_utils
from metatlas.plots.dill2plots import convert_to_centroid

logger = logging.getLogger(__name__)

Expand Down Expand Up @@ -54,6 +55,9 @@ def arrange_ms2_data(metatlas_dataset, keep_nonmatches, do_centroid):
if 'data' not in file_compound_data['data']['msms']:
continue

if 'rt' not in file_compound_data['data']['msms']['data']:
continue

cid = file_compound_data['identification']
cid_name = cid.compound[0].name
precursor_mz = cid.mz_references[0].mz
Expand Down

0 comments on commit 6a49640

Please sign in to comment.