Index: /trunk/ppStack/src/ppStackArguments.c
===================================================================
--- /trunk/ppStack/src/ppStackArguments.c	(revision 16621)
+++ /trunk/ppStack/src/ppStackArguments.c	(revision 16622)
@@ -122,4 +122,6 @@
     psMetadataAddStr(arguments, PS_LIST_TAIL, "-psf-model", 0, "Model name for PSF generation", "PS_MODEL_RGAUSS");
     psMetadataAddS32(arguments, PS_LIST_TAIL, "-psf-order", 0, "Spatial order for PSF generation", 3);
+    psMetadataAddBool(arguments, PS_LIST_TAIL, "-variance", 0, "Use variance for rejection?", false);
+    psMetadataAddBool(arguments, PS_LIST_TAIL, "-safe", 0, "Play safe with small numbers of pixels to combine?", false);
 
     if (argc == 1 || !psArgumentParse(arguments, &argc, argv) || argc != 3) {
@@ -174,4 +176,16 @@
     }
 
+    if (psMetadataLookupBool(NULL, arguments, "-variance") ||
+        psMetadataLookupBool(NULL, recipe, "VARIANCE")) {
+        psMetadataAddBool(config->arguments, PS_LIST_TAIL, "VARIANCE", 0,
+                          "Use variance for rejection?", true);
+    }
+
+    if (psMetadataLookupBool(NULL, arguments, "-safe") ||
+        psMetadataLookupBool(NULL, recipe, "SAFE")) {
+        psMetadataAddBool(config->arguments, PS_LIST_TAIL, "SAFE", 0,
+                          "Play safe with small number of pixels to combine?", true);
+    }
+
     psTrace("ppStack", 1, "Done reading command-line arguments\n");
     psFree(arguments);
Index: /trunk/ppStack/src/ppStackReadout.c
===================================================================
--- /trunk/ppStack/src/ppStackReadout.c	(revision 16621)
+++ /trunk/ppStack/src/ppStackReadout.c	(revision 16622)
@@ -31,4 +31,5 @@
 
     // Get the recipe values
+    bool mdok;                          // Status of MD lookup
     int iter = psMetadataLookupS32(NULL, config->arguments, "ITER"); // Rejection iterations
     float combineRej = psMetadataLookupF32(NULL, config->arguments, "COMBINE.REJ"); // Combination threshold
@@ -36,4 +37,6 @@
     psMaskType maskBlank = psMetadataLookupU8(NULL, config->arguments, "MASK.BLANK"); // Mask for blank reg.
     float threshold = psMetadataLookupF32(NULL, config->arguments, "THRESHOLD.MASK"); // Threshold for mask deconvolution
+    bool useVariance = psMetadataLookupBool(&mdok, config->arguments, "VARIANCE"); // Use variance for rejection?
+    bool safe = psMetadataLookupBool(&mdok, config->arguments, "SAFE"); // Play safe when combining small numbers of pixels?
 
     int num = readouts->n;              // Number of inputs
@@ -106,5 +109,5 @@
     }
 
-    if (!pmStackCombine(outRO, stack, maskBad, maskBlank, iter, combineRej)) {
+    if (!pmStackCombine(outRO, stack, maskBad, maskBlank, iter, combineRej, useVariance, safe)) {
         psError(PS_ERR_UNKNOWN, false, "Unable to combine input readouts with rejection.");
         psFree(fpaList);
@@ -175,5 +178,5 @@
 #endif
 
-    if (!pmStackCombine(outRO, stack, maskBad, maskBlank, 0, combineRej)) {
+    if (!pmStackCombine(outRO, stack, maskBad, maskBlank, 0, combineRej, useVariance, safe)) {
         psError(PS_ERR_UNKNOWN, false, "Unable to combine input readouts.");
         psFree(fpaList);
