How to calculate sum of group in OpenLab CDS2 ?

Hello Everyone!

I need to calculate a formula using a OpenLab CDS2, I know to separate in groups peaks interest, but I don't know to calculate using groups and report it using the formula allowed. 

Can you help me, please?

Parents
  • Hello,

    Are S1, S2, S3 timed groups or named groups? I will assume you are working with the compound amount in the formula. See below for the 2 calculations in custom calculator. In the example I am doing the calculation per injection. 

    Marty

    CurrentInjection.AllPeaksAndGroupsByName("S1").Select(function(x) x.Compound_Amount).First * 100 / (CurrentInjection.AllPeaksAndGroupsByName("S1").Select(function(x) x.Compound_Amount).First + 0.83 * CurrentInjection.AllPeaksAndGroupsByName("S2").Select(function(x) x.Compound_Amount).First + CurrentInjection.AllPeaksAndGroupsByName("S3").Select(function(x) x.Compound_Amount).First)

    CurrentInjection.AllPeaksAndGroupsByName("S2").Select(function(x) x.Compound_Amount).First * 0.83 * 100 / (CurrentInjection.AllPeaksAndGroupsByName("S1").Select(function(x) x.Compound_Amount).First + 0.83 * CurrentInjection.AllPeaksAndGroupsByName("S2").Select(function(x) x.Compound_Amount).First + CurrentInjection.AllPeaksAndGroupsByName("S3").Select(function(x) x.Compound_Amount).First)

Reply
  • Hello,

    Are S1, S2, S3 timed groups or named groups? I will assume you are working with the compound amount in the formula. See below for the 2 calculations in custom calculator. In the example I am doing the calculation per injection. 

    Marty

    CurrentInjection.AllPeaksAndGroupsByName("S1").Select(function(x) x.Compound_Amount).First * 100 / (CurrentInjection.AllPeaksAndGroupsByName("S1").Select(function(x) x.Compound_Amount).First + 0.83 * CurrentInjection.AllPeaksAndGroupsByName("S2").Select(function(x) x.Compound_Amount).First + CurrentInjection.AllPeaksAndGroupsByName("S3").Select(function(x) x.Compound_Amount).First)

    CurrentInjection.AllPeaksAndGroupsByName("S2").Select(function(x) x.Compound_Amount).First * 0.83 * 100 / (CurrentInjection.AllPeaksAndGroupsByName("S1").Select(function(x) x.Compound_Amount).First + 0.83 * CurrentInjection.AllPeaksAndGroupsByName("S2").Select(function(x) x.Compound_Amount).First + CurrentInjection.AllPeaksAndGroupsByName("S3").Select(function(x) x.Compound_Amount).First)

Children
Was this helpful?