Skip to content

Commit

Permalink
Cleanup of other stuff tested for parent genotype inference (stochast…
Browse files Browse the repository at this point in the history
…ic changes to desymmetrize). #1
  • Loading branch information
cnettel committed Apr 25, 2016
1 parent 5b1439e commit feed28d
Showing 1 changed file with 0 additions and 27 deletions.
27 changes: 0 additions & 27 deletions cnF2freq.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4190,33 +4190,6 @@ template<bool full, typename reporterclass> void doit(FILE* out, bool printalot
ind->markerdata[j] = make_pair(bestvals[0], bestvals[1]);
ind->markersure[j] = make_pair(bestsure[0], bestsure[1]);
}
/*else if (ind->markerdata[j].first == ind->markerdata[j].second && ind->markerdata[j].first == UnknownMarkerVal)
{
for (int a = 0; a < 2 && !foundbest; a++)
{
map<MarkerVal, double> sums;
double sum = 0;
for (map<pair<MarkerVal>, double>::iterator i = ind->infprobs[j][a].begin(); i != ind->infprobs[j][a].end(); i++)
{
sums[i->first] += i->second;
sum += i->second;
}
if (sum < 0.1) sum = 0.1;
for (map<pair<MarkerVal>, double>::iterator i = sums.begin(); i != sums.end() && !foundbest; i++)
{
// fprintf(out, "Individual %d stochastic tryout at marker %d, :%d:, was %d:%d %lf M\n", ind->n, j, i->first, i->first, ind->markerdata[j].second, i->second / sum);
if (i->second >= sum * 0.5)
{
ind->markerdata[j] = make_pair(i->first, UnknownMarkerVal);
ind->markersure[j] = make_pair(0.999, 0);
fprintf(out, "Individual %d stochastic fix at marker %d, :%d:, was %d:%d %lf M\n", ind->n, j, i->first, ind->markerdata[j].first, ind->markerdata[j].second, i->second / sum);
foundbest = true;
}
}
}
}*/
}
for (int a = 0; a < 2; a++)
{
Expand Down

0 comments on commit feed28d

Please sign in to comment.