From 5ee7e90844b16ff132278c6deb65a2b79ae95581 Mon Sep 17 00:00:00 2001 From: Frederick Muriuki Muriithi Date: Fri, 16 Aug 2024 13:26:31 -0500 Subject: Ignore comment lines. --- r_qtl/r_qtl2.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/r_qtl/r_qtl2.py b/r_qtl/r_qtl2.py index 9da4081..3d02977 100644 --- a/r_qtl/r_qtl2.py +++ b/r_qtl/r_qtl2.py @@ -72,6 +72,8 @@ def transpose_csv( def __read_by_line__(_path): with open(_path, "r", encoding="utf8") as infile: for line in infile: + if line.startswith("#"): + continue yield line transposed_data= (f"{linejoinerfn(items)}\n" for items in zip(*( -- cgit v1.2.3