I recently added a new script to the File Exchange, called theImage Analyzer. It extends the functionality of some scripts that I wrote previously for image handling. Like with previous scripts, you can open an image and it will be displayed in a window as well as create a data table from the image. But now, from the data table you can perform your analysis, such as a Distribution of the intensity values. You can then select in the Distribution (or other visualization), in the data table or in the image and all three will be updated to show the selection.
Selection in the image is shown by using transparency on the non-selected pixels so that the selected pixels appear highlighted. You can apply a background color to the image window so that transparent pixels do not show as white, but rather they will show as the background color you choose.
This script will make it easy to relate individual pixels in the image to their corresponding individual rows in the data table. Let me know what you think and what would be the next step for this type of app.