docstr: Calculate measurements on an image set
docstr_tok: ["Calculate","measurements","on","an","image","set"]
code: def run(self, workspace):
      """Calculate measurements on an image set"""
      col_labels = [
          "First image",
          "Second image",
          "Objects",
          "Measurement",
          "Value",
      ]
      statistics = []
      if len(self.images_list.value) < 2:
          raise ValueError(
              "At least 2 images must be selected for analysis."
          )
      for first_image_name, second_image_name in self.get_image_pairs():
          if self.wants_images():
              statistics += self.run_image_pair_images(
                  workspace, first_image_name, second_image_name
              )
          if self.wants_objects():
              for object_name in self.objects_list.value:
                  statistics += self.run_image_pair_objects(
                      workspace,
                      first_image_name,
                      second_image_name,
                      object_name,
                  )
      if self.show_window:
          workspace.display_data.statistics = statistics
          workspace.display_data.col_labels = col_labels
  
imports: import numpy
  import scipy.ndimage
  import scipy.stats
  from cellprofiler_core.constants.measurement import COLTYPE_FLOAT
  from cellprofiler_core.module import Module
  from cellprofiler_core.setting import Divider, Binary, ValidationError
  from cellprofiler_core.setting.choice import Choice
  from cellprofiler_core.setting.subscriber import LabelListSubscriber, ImageListSubscriber
  from cellprofiler_core.setting.text import Float
  from cellprofiler_core.utilities.core.object import size_similarly
  from centrosome.cpmorphology import fixup_scipy_ndimage_result
  from scipy.linalg import lstsq
label_desc: Use image node_id 8 for calling the MeasureColocalization obj's underlying member method code with example usage: obj.run(workspace) without return types