In this section of the tutorial you will learn:
• | How to export only the numeric data from a 96 Well Plate CellProfiler pipeline. |
The CellProfiler modules that are needed or must be amended for export to FCS Express in this section are LoadImages and ExportToSpreadsheet. The completed pipeline for this example can be found in the Tutorial Sample Data archive and is named Section3pipelineCOMPLETED.cp. The completed pipeline is meant to be used as a template for comparison to your pipeline and represents the finished product of this tutorial.
The example data set we will be using can be downloaded from the CellProfiler Examples website and is labeled "Human cytoplasm-nucleus translocation assay (SBS Bioimage)".
CellProfiler Example Link
The steps for exporting data from CellProfiler have been broken down by module according to the Section3pipeline.cp. After loading the Section3pipeline.cp, follow the steps below to amend the pipeline to prepare for export to FCS Express.
Selecting Default Input and Output Folders
To organize your data correctly for FCS Express, first ensure that the default input (where your images are stored) and output folders in CellProfiler are set to the same folder in the Input/Output Folder window.
Note: The DefaultOUT.mat file will also be exported to the Output Folder. This file is for use in MATLAB. If you do not wish to use this file, we recommend deleting it to conserve disk space.
LoadImages Module Setup
In order for FCS Express to recognize your data throughout the pipeline, metadata from the image file names must be extracted. A Regular Expression must be defined to find the metadata in the file name or path of the data by following these steps:
1. | Click on the drop-down list labeled Extract metadata from where?. |
2. | Select which metadata you wish to use. For this example, choose File name. |
3. | Enter the "Regular Expression" you wish to use in the field labeled Regular expression that finds metadata in the file name. For this example we will use "Channel2-[0-9]{2}-(?P<Row>[A-H])-(?P<Column>[0-9]{2}).tif" which defines the plate location of the image by Row Letter and Column Number found in the image name. |
Notes:
• | Follow these links for a tutorial on "Regular Expressions" and how to translate regular expressions. |
• | Setting up metadata and regular expressions only has to be done for one image in the set. For this example, it has been set up for channel 2. |
• | The regular expression output names: Well, Row, Column, and Col may only be used with plate based or montage imaging experiments. Using any of these names for a single image experiment will result in a non-working export. |
ExportToSpreadsheet Module
Now that all of the images and object image masks have been defined and saved for analysis, you must now ask CellProfiler to export the measurements you wish to view in FCS Express. For this example, we will export all measurements.
(Note: If you would like to only export certain parameters please see the Selecting Individual Parameters for CellProlifer Export section)
4. | Select the ExportToSpreadsheet module. |
5. | Select or enter the column delimiter by choosing Comma (",") from the drop-down list. |
6. | Uncheck the Prepend the output file name to the data file names? box. |
7. | Choose Output file location as Default Output Folder from the drop-down list. |
8. | Uncheck Export all measurements?. |
9. | Choose Image from the first Data to export drop-down list. |
10. | Uncheck Use the object name for the file name?. |
11. | Set the file name as Image.cptoc. |
12. | Choose Add another data set. |
13. | Choose Nuclei from the second Data to export drop-down list. |
14. | Uncheck Use the object name for the file name. |
15. | Set the file name as nuclei.cpout. |
16. | Repeat steps 12-15 for "Cells" and set the file name as cells.cpout. |
The ExportToSpreadsheet module options should look like Figure T24.25 when you are done.
Note 1: on file extensions: ".cptoc" stands for CellProfiler Table of Contents and ".cpout" stands for CellProfiler Output. The "Image.cptoc" file stores information about the location and number of images for all objects processed in the pipeline, while the separate "Nuclei.cpout" and "Cells.cpout" store the actual listmode data associated with individual objects and analysis. There should be a separate ".cpout" file defined for each object mask defined in CellProfiler. Only one "Image.cptoc" file is needed.
Note 2:The name of your .cpout file must begin with the name of the object data you are exporting and may only be include the object name and regular expressions. For example: the file names nuclei.cpout and nuclei_<regular express>.cpout will result in a proper export while dataset1nuclei.cpout or <regularexpression>_nuclei.cpout will resulting in a non-working export.
Figure T24.25 ExportToSpreadsheet Module
17. | Select Analyze images to run the pipeline. The folder where your images are stored will now contain the cells.cpout, nuclei.cpout and Image.cptoc files (Figure T24.26). |
Note: The DefaultOUT.mat file will also be exported to the Output Folder. This file is for use in MATLAB, if you do not wish to use this file we recommend deleting it to conserve disk space.
Figure T24.26 Data Only Output Files
Next, we will import and analyze the numeric data.