Name

Expression filter

This output allows filtering on and changing individual localization fields. It is distributed into two parts: The simple input fields for minimum localization strength, linear drift correction and maximum two kernel improvement give easy access to often-needed manipulations, while the more complex test-based expressions give full access to all localization fields.

The number of Value to assign to and Expression to assign from fields in this output is variable and can be changed with the Number of expressions field. These fields form pairs called "actions", and all of the actions take effect. The order of application is top-to-bottom.

Configuration items

Minimum localization strength

If this field is enabled, all localizations with a strength lower than its value are discarded and not displayed or stored in the suboutputs. The localization strength denotes the total signal detected in the PSF, i.e. the integral of the point spread function.

Linear drift correction

If this field is enabled, all localizations are shifted in space by an amount proportional to the time coordinate of their detection. This is used to implement linear drift correction.

Maximum two kernel improvement

If this field is checked, all localizations with a two-kernel improvement (quotient of residues with two kernels and residues with one kernel) greater than the given value are discarded. This value is used for artifact suppression and is only available when Compute two kernel improvement has been checked.

Value to assign to

This option box determines the effect of the action. It can either take the value of Filter, in which case Expression to assign from must give a boolean result, or a variable name, in which case Expression to assign from must give a numerical result which matching dimensions. The possible variable names are formed by applying the modifiers from Table 2, “Variable name modifiers for expressions” to Table 1, “Variable base names for expressions”, with examples in Table 3, “Variable example names for expressions”.

Expression to assign from

This text field gives an arithmetic expression for the value of the action. An expression consists of variables explained in Value to assign to and constants, linked by the usual arithmetic operators. Constants are given as numbers with units, which can be m, ADC or fr for meters, camera A/D counts of frames, respectively, and be prefixed with the usual SI prefixes (with u for μ). The available operators are given in Table 4, “Operators in expressions”. Examples for complete actions are listed in Table 5, “Example actions”

Table 1. Variable base names for expressions

Variable base nameDimensionTypeMeaning
posm3D vectorPosition in sample space
ampADCscalarIntensity of emission
framefrscalarTime of emission
psffwhmm2D vectorPSF model's full width at half maximum
fishydimensionlessscalarTwo-kernel improvement
chisqdimensionlessscalarFit residues. For least-squares fitting, this value gives the sum of squared deviations between PSF model and data in photons squared. For MLE fitting, this value gives the total likelihood score. In both cases, the value is not normed in any way and unlikely to be comparable between measurements.
fluodimensionlessscalarFluorophore type (0 for first fluorophore, 1 for second, etc.)
bgADCscalarLocal background intensity

Table 2. Variable name modifiers for expressions

ModifierMeaning
x… in X dimension
y… in Y dimension
z… in Z dimension
sigmauncertainty of …
minlower bound of …
maxupper bound of …

Table 3. Variable example names for expressions

Example variable nameMeaning
posxLocalization's X coordinate
posminyHighest possible Y localization coordinate
fluoFluorophore type

Table 4. Operators in expressions

OperatorResult typeMeaning
(n1)numericalgrouping of numerical expressions
n1^n2numericalexponentiation
n1 * n2, n1 / n2numericalmultiplication, division
n1 + n2, n1 - n2numericaladdition, subtraction
(b1) ? n1 : n2numericalchoice operator (if b1 is true, use n1, else n2
n1 == n2, n1 != n2, n1 = n2, n1 >= n2, n1 <= n2, n1 > n2, n1 < n2booleancomparison for equality, inequality, equality (same as ==), greater-equality, less-equality, greater, less
!b1booleannegation
b1 && b2booleanconjunction (and)
b1 || b2booleandisjunction (or)

Table 5. Example actions

Value to assign toExpression to assign fromIntention
Filterfluo = 0Only show localizations from the first fluorophore
Filterposx > 1 umOnly show localizations right of a line at 1 μm
Filteramp < 5 kADCDiscard emissions with intensities above 5000 counts
Filterposx > 2300 nm && posx < 2800 nm && posy > 1800 nm && posy < 2200 nm && frame < 500 frLimit region of interest to a single bead early in the acquisition to calibrate 3D
posz8 nm/fr * frameSet a Z ground truth raising 8 nanometre per frame
amp(fluo == 0) ? 1.5 * amp : 1 * ampMake all localizations from the first fluorophore type more intense by a half