MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / setLuciphorTargetMods_

Method setLuciphorTargetMods_

src/topp/LuciphorAdapter.cpp:387–410  ·  view source on GitHub ↗

set modifications changed by LuciPHOr2

Source from the content-addressed store, hash-verified

385
386 // set modifications changed by LuciPHOr2
387 ExitCodes setLuciphorTargetMods_(AASequence& seq, String seq_luciphor, const map<String, String>& target_mods_conv)
388 {
389 for (Size i = 0; i < seq_luciphor.length(); ++i)
390 {
391 char aa = seq_luciphor[i];
392 if (std::islower(aa))
393 {
394 map<String, String>::const_iterator iter = target_mods_conv.find(String(aa).toUpper());
395 if (iter != target_mods_conv.end())
396 {
397 if (seq.getResidue(i).isModified())
398 {
399 writeLogError_("Error: ambiguous modifications on AA '" + iter->first + "' (" + seq.getResidue(i).getModificationName() + ", " + iter->second + ")");
400 return PARSE_ERROR;
401 }
402 else
403 {
404 seq.setModification(i, iter->second);
405 }
406 }
407 }
408 }
409 return EXECUTION_OK;
410 }
411
412 void addScoreToMetaValues_(PeptideHit& hit, const String score_type)
413 {

Callers

nothing calls this directly

Calls 8

toUpperMethod · 0.80
getResidueMethod · 0.80
getModificationNameMethod · 0.80
StringClass · 0.50
findMethod · 0.45
endMethod · 0.45
isModifiedMethod · 0.45
setModificationMethod · 0.45

Tested by

no test coverage detected