anchor.diff:          
       module MyQuant = 
   
  -        //
  +
  +        //TODO add to SignalDetection
  +        let idxOfHighestLabeledPeakBy (labeledData: Tag<Care.Extrema,(float*float)>[]) (labelV:Care.Extrema) xValue = 
  +            if labeledData |> Array.isEmpty then None
  +            else
  +            labeledData  
  +            |> Array.mapi (fun i x -> i, x) 
  +            |> Array.filter (fun (i,x) -> x.Meta = labelV)
  +            |> fun farr -> 
  +                match farr with
  +                | farr when farr |> Array.isEmpty -> 
  +                    None     
  +                | _ ->  
  +                    farr 
  +                    |> Array.maxBy (fun (idx,value) -> snd value.Data ) 
  +                    |> Some
  +                
  +        //TODO add to SignalDetection
           let idxOfClosestLabeledPeak (labeledData: Tag<Care.Extrema,(float*float)>[]) (labelV:Care.Extrema) xValue = 
               if labeledData |> Array.isEmpty then None
               else
  
positive.code:                              )
              // Step 3: find closest Peak to MS2 scantime
              let closestPeakIdx = 
                  idxOfClosestLabeledPeak labeledSndDevData SignalDetection.Care.Extrema.Positive scanTime
              // TODO with F# 4.1 replace with OK, Error Pattern
              if closestPeakIdx.IsNone then None, 1
              else
  
negative.code:                     //
                      Some (createQuantificationResult FitBothModels.True modelF area sEoE deltaScanTimePeakApex yMaxModel yMaxXic), 11
      
  
  
  