void MapAlignmentTransformer::applyToBaseFeature_(BaseFeature & feature,
                                                    const TransformationDescription & trafo)
  {
    // transform feature position:
    DoubleReal rt = feature.getRT();
    feature.setRT(trafo.apply(rt));

    // adapt RT values of annotated peptides:
    if (!feature.getPeptideIdentifications().empty())
    {
      transformSinglePeptideIdentification(feature.getPeptideIdentifications(),
                                           trafo);
    }
  }
  void MapAlignmentTransformer::applyToBaseFeature_(
    BaseFeature& feature, const TransformationDescription& trafo,
    bool store_original_rt)
  {
    // transform feature position:
    double rt = feature.getRT();
    if (store_original_rt) storeOriginalRT_(feature, rt);
    feature.setRT(trafo.apply(rt));

    // adapt RT values of annotated peptides:
    if (!feature.getPeptideIdentifications().empty())
    {
      transformRetentionTimes(feature.getPeptideIdentifications(), trafo,
                              store_original_rt);
    }
  }
Beispiel #3
0
 GridFeature::GridFeature(const BaseFeature& feature, Size map_index,
                          Size feature_index) :
   feature_(feature),
   map_index_(map_index),
   feature_index_(feature_index),
   annotations_()
 {
   const vector<PeptideIdentification>& peptides =
     feature.getPeptideIdentifications();
   for (vector<PeptideIdentification>::const_iterator pep_it =
          peptides.begin(); pep_it != peptides.end(); ++pep_it)
   {
     if (pep_it->getHits().empty())
       continue; // shouldn't be the case
     annotations_.insert(pep_it->getHits()[0].getSequence());
   }
 }