aboutsummaryrefslogtreecommitdiff
path: root/src/gemma_io.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gemma_io.cpp')
-rw-r--r--src/gemma_io.cpp11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/gemma_io.cpp b/src/gemma_io.cpp
index 45d1eb4..962e0c0 100644
--- a/src/gemma_io.cpp
+++ b/src/gemma_io.cpp
@@ -150,7 +150,7 @@ std::istream &safeGetline(std::istream &is, std::string &t) {
// Read SNP file. A single column of SNP names.
bool ReadFile_snps(const string file_snps, set<string> &setSnps) {
- debug_msg("entered");
+ debug_msg("enter ReadFile_snps");
setSnps.clear();
igzstream infile(file_snps.c_str(), igzstream::in);
@@ -329,6 +329,9 @@ bool ReadFile_anno(const string &file_anno, map<string, string> &mapRS2chr,
mapRS2bp[rs] = b_pos;
mapRS2cM[rs] = cM;
}
+ // for (auto& [key, value] : mapRS2bp) {
+ // cerr << key << endl;
+ //}
infile.close();
infile.clear();
@@ -693,6 +696,9 @@ bool ReadFile_geno(const string &file_geno, const set<string> &setSnps,
file_pos = 0;
auto count_warnings = 0;
auto infilen = file_geno.c_str();
+ // for (auto& [key, value] : mapRS2bp) {
+ // cerr << key << endl;
+ // }
while (!safe_get_line(infile, line).eof()) {
ch_ptr = strtok_safe2((char *)line.c_str(), " ,\t",infilen);
rs = ch_ptr;
@@ -714,8 +720,7 @@ bool ReadFile_geno(const string &file_geno, const set<string> &setSnps,
if (mapRS2bp.count(rs) == 0) {
if (is_debug_mode() && count_warnings++ < 10) {
- std::string msg = "Can't figure out position for ";
- msg += rs;
+ std::string msg = "Can't figure out position for <" + rs + ">";
debug_msg(msg);
if (count_warnings == 10)
debug_msg("Skipping similar warnings");