diff --git a/parser.py b/parser.py index 25e45c7..328c3a5 100644 --- a/parser.py +++ b/parser.py @@ -14,8 +14,9 @@ def extract_adapters(files) -> Tuple[Series, List]: all_adapters = DataFrame() for entry in files: tables = read_html(entry) - adapter_sequences = tables[1].Sequence - all_adapters = all_adapters.append(adapter_sequences) + if len(tables) > 1: + adapter_sequences = tables[1].Sequence + all_adapters = all_adapters.append(adapter_sequences) processed_adapters = preprocess_dataframe(all_adapters) stats = [ processed_adapters.str.len().mean(),