Custom calculation not working after manual integration

I have a variety of custom calculation that I display and while most of them automatically update when I perform a manual integration, I have two calculations that do not do so, showing up as "0%". 

I can still get them to update, but only if I right click on the injection or injection set and select "Link selected injections to selected method".

After clicking on this, the calculations once again will work.

Calculation performed on the column data:

Potential CBD calculation: =IIf(Compound_Name="CBD",FormatPercent(Round(CCR(Injection_CustomCalculationResults,"Potential_CBD"),2)/100),"")

 

% Per Weight calculation: =FormatPercent((Compound_Amount*CFE((Sample_CustomFields),"IPA Weight/mL")/CFE((Sample_CustomFields),"HPLC Amt/mL")*CFE((Sample_CustomFields),"HPLC IPA Amt/mL")/CFE((Sample_CustomFields),"Sample Weight/g"))/1000000)

Calculation performed in Custom Calculator:


Is there anyway to have these perform automatically without having to "Link Selected Injections" again?
Parents
  • Hello,

     

    What version of CDS 2.x are you using? What happens if you reprocess all are the results still 0? What happens if you save your results and reopen them in DA?

     

    Marty Adams

  • Marty,

     

    Thanks for the reply.  In answer to your questions:

    1. I am running version 2.4 (specifically Build 2.204.0.661).
    2. Interesting question about reprocessing.  If I right click on an individual injection and select "Reprocess selected injections", it is still zero.  However, if I either right click on the sequence and select "Reprocess selected injections" or I click on the "Reprocess All" link in the menu bar, the results are no longer zero.
    3. If the results are zero, saving the results and reopening them in DA does not change anything - still zero.  I tried both closing and reopening the file, as well as completely shutting down DA.

     

    Observations and thoughts:

    1. When the results are first loaded, all calculations work fine - no zeros.  It only becomes zero after manual integration.
    2. I can take two injections which need manual integration. I can perform manual integrations on both, reprocess and have correctly calculated results (non-zero) on both.  I then take only one of the injections and manually integrate the result again.  The results for both injections are once again zero, until I reprocess or link selected injection again.
    3. I noticed that the "Potential CBD" calculation is mainly performed in the Custom Calculator, and the "% per weight" calculation is perform in the report column.  Is is possible that the custom calculator code is only called on load, while the report calculations are called on refresh?  That would explain why it is necessary to reprocess results or relink the method in order to call the CC calculations.
  • So this is all linked to the way customer calculator works in a result set. For the same reason that you must have all injections in the sequence linked to methods that call the same custom calculation file, you also must process the entire data set at once. Manual integration causes that injection to recalculate which breaks this rule so CC values are not calculated. I think you will find the warning below shown when you manually integrate or reprocess only selected injections. Part of relinking the method is to reprocess so that fixed your issue as does just reprocessing. So if you do manual integrations when you are using a CCF you must reprocess the data set.

     

    Marty Adams

     

     

     

Reply
  • So this is all linked to the way customer calculator works in a result set. For the same reason that you must have all injections in the sequence linked to methods that call the same custom calculation file, you also must process the entire data set at once. Manual integration causes that injection to recalculate which breaks this rule so CC values are not calculated. I think you will find the warning below shown when you manually integrate or reprocess only selected injections. Part of relinking the method is to reprocess so that fixed your issue as does just reprocessing. So if you do manual integrations when you are using a CCF you must reprocess the data set.

     

    Marty Adams

     

     

     

Children
Was this helpful?