Commit 95d6a9f3 authored by Carsten Kemena's avatar Carsten Kemena

allow to best match files

parent afeaacd0
......@@ -288,11 +288,12 @@ main(int argc, char const *argv[])
fs::path detailedFile;
po::options_description hiddenO("Hidden options");
int w;//, m;
fs::path m;
fs::path m, m2;
hiddenO.add_options()
("detailed", po::value<fs::path>(&detailedFile), "The output file for the detailed results")
("window_size", po::value<int>(&w), "The window size")
("match", po::value<fs::path>(&m), "The number of matches required")
("match2", po::value<fs::path>(&m2), "The number of matches required")
;
allOpts.add(general).add(outputO).add(translateO).add(hiddenO);
......@@ -385,28 +386,34 @@ main(int argc, char const *argv[])
//fs::path tmp = outFile;
// tmp += to_string(max_dist) + "_" + to_string(min_count) + ".txt";
//
map<unsigned short, int> domain2match;
map<unsigned short, int> domain2match, domain2match2;
std::ifstream file(m.string());
unsigned short p_id;
int threshold;
while(!file.eof())
{
file >> p_id >> threshold; // extracts 2 floating point values seperated by whitespace
domain2match[p_id] = threshold;
// do something with them
}
//
AlgorithmPack::Output out(outFile);
file.close();
file.open(m2.string());
while(!file.eof())
{
file >> p_id >> threshold; // extracts 2 floating point values seperated by whitespace
domain2match2[p_id] = threshold;
}
file.close();
AlgorithmPack::Output out(outFile);
if (!noHeader)
printHeader(radiantVersion, pfamLike, translate, inFile, databaseFile, out);
for (size_t i = 0; i< seqSet.size(); ++i)
{
auto &assignment = assignments[i];
// auto da = words2arrangement(assignment, m, w);
auto da = words2arrangement(assignment, domain2match, 10);
//if (da.size() == 0)
// da = words2arrangement(assignment, 3, 5);
if (da.size() == 0)
da = words2arrangement(assignment, domain2match2, 5);
if (pfamLike)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment