例 5:少なくとも 1 つの化合物が見つからない場合のデータのフラグ

  • スコープ:注入データ

  • データ型:文字列型

  • [注入データ]ノードで[MissingCompound]関数を検索します。

If(CurrentInjection.AllMissingCompounds.Count>=1, "missing","No Missing")

あるいは、LINQ の式を使用します。

If(CurrentInjection.AllMissingCompounds.Any, "Flag","")

別の方法:

  • スコープ:注入データ

  • データ型:ブール型

  • 式:Count(Currentinjection.AllMissingCompounds)<>0

さらに詳細な式も作成できます。たとえば、見つからない化合物がある場合その数を返すには、次のようになります。

  • スコープ:注入データ

  • データ型:文字列型

  • 式:If (Count(CurrentInjection.AllMissingCompounds) = 0, "No Calibrated Peak(s) Missing ", "Fail " &(Count(CurrentInjection.AllMissingCompounds) &" Calibrated Peak(s) Not Found "))

見つからない化合物がある場合その名前を返すには、次のようになります。

  • スコープ:注入データ

  • データ型:文字列型

  • 式:If (Count(CurrentInjection.AllMissingCompounds) = 0, "No Calibrated Peak(s) Missing ", "Fail " & string.join(" ",CurrentInjection.AllMissingCompounds.select(function(x) x.Compound_Name.tostring())))