| 170 | } |
| 171 | |
| 172 | void CoverageFile::doMean(RecordOutputMgr *outputMgr, RecordKeyVector &hits) |
| 173 | { |
| 174 | size_t sum =0; |
| 175 | for (size_t i= 0; i < _queryLen; i++) { |
| 176 | sum += _depthArray[i]; |
| 177 | } |
| 178 | ostringstream s; |
| 179 | float mean = ((float)sum / (float)_queryLen); |
| 180 | char *meanString; |
| 181 | asprintf(&meanString, "%0.7f", mean); |
| 182 | s << meanString; |
| 183 | _finalOutput.append(s.str()); |
| 184 | outputMgr->printRecord(hits.getKey(), _finalOutput); |
| 185 | } |
| 186 | |
| 187 | |
| 188 | void CoverageFile::doHist(RecordOutputMgr *outputMgr, RecordKeyVector &hits) |
nothing calls this directly
no test coverage detected