Sie sind auf Seite 1von 56

Supplemental Information, Scientific Imaging with

Photoshop: Methods, Measurement and Output


Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Table of Contents

Input
1 Adobe Camera Raw Steps
6 Camera Calibration Information and Links
7 Low Resolution Input Sources
10 Acquisition for White/Black Values when Exceeding Dynamic Range

Photoshop Procedures
11 Tools and Functions in Photoshop
28 Including Scale Bars
32 Saving and Archiving
36 Working with Graphs
38 Image Stack Alternatives and Making a Layered Stack in Pre-CS Photoshop

Output
42 Inkjet Paper Profiling Information and Links
44 Video and Web Outputs

Quantitation
46 Stereology Probes
47 Quantitation Example

Downloads
Download additional supplemental material and files from quickphotoshop.com
(http://www.rawlight.com/book_info.com).

Authors note: The supplemental materials were both written and designed on my own. These are be-
ing made available until the publisher of the accompanying book (New Riders Press) can assemble this
information on their web page. Because of time limitations, I could not match the design throughout this
collection of supplemental material.

Jerry Sedgewick

Adobe, Photoshop and company product names are registered trademarks of Adobe Systems Incorporated. Windows, Power-
point, Word and other company product names are registered trademarks of Microsoft, Inc. Sony is the registered name of the
Sony Corporation. All other product names and services in this supplement are used in editorial fashion with no intention of
infringement of trademarks.
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Adobe Camera Raw Steps


While many of the adjustments to images can be made in Photoshop, the use of the Adobe
Camera Raw plug can provide advantages. These are limited to only the kinds of files saved in
the respective manufacturers
Raw file format, such as the .CR2 files for the Canon digital single lens reflex camera. Among
the advantages are the following:
To maintain the highest quality image, Adobe Camera Raw is used with Raw images.
To keep color values identical from exposure to exposure.
When used with Adobe Bridge, to make the workflow more efficient when working with
large numbers of images.
Discussions and explanation of the Adobe Camera Raw (ACR) plug-in comprise entire books,
and so this supplement covers only some basic functions typically used in the sciences. The
section on ACR in the Scientific Imaging with Photoshop: Methods, Measurement and Out-
put book did not go into an extended explanation about why a Raw file is preferable to a TIFF
or JPEG. For more information about the merits of the Raw format, go to http://www.cam-
Note: bridgeincolour.com/tutorials/RAW-file-format.htm. This website, Cambridge in Colour, also
The tonal contains concise and accurate information about a number of topics related to digital imaging.
adjustment
steps that fol- White balancing can be accomplished using Color Temperature and Tint sliders. To keep color
low may not values identical from exposure to exposure As Shot is chosen, with, perhaps, a consistently
all maintain chosen numeric change in the Tint slider. As Shot is chosen when manual white balancing
color preci- was done before imaging sessions in which a consistent light source was used. Especially for
sion, with the colorimetric studies, manual white balancing of digital cameras must be done for consistent
exception and repeatable color detection!
of Exposure
and Black Rather than open every image in Photoshop, settings can be adjusted through Adobe Bridge.
adjustments. These settings include expanding or contracting the range of pixel values for reproduction,
Other tonal noise reduction, adjusting colors to pre-calibrated standards, and possible hue and saturation
adjustment adjustments.
tools have not
been tested. A series of possible steps follow, along with a workflow in which ACR settings are applied to a
series of images without having to open images one by one in Photoshop.

Adobe Camera Raw Steps


Here are some typical steps
taken in the plug-in to Pho-
toshop CS3, Adobe Camera
Note: Raw 4.1:
ACR is 1. Once the Raw image ap-
guessing pears in Adobe Camera
at the color Raw, be sure the settings
temperature at the bottom of the im-
of the light age window are set to the
source at desired working space, bit
a value of
depth and resolution. In
3250 Kelvin
and a Tint of the image above, it is set
+8. When to ProPhoto RGB (for a
the picture brightfield image), at a 16-
was taken, bit depth, and at a resolu-

1
tion that matches the camera resolution. The ppi is moot at this point (the sampling resolution is the
number of pixels across and down): ppi will be set for the output later on in Photoshop. The editing
space for color can also be set to Adobe 1998, if that is desired; or, if the image must maintain a gamma
of 1 to preserve the relationship of grayscale values, use the CIE 1931 D65 or Gray color space. Use
the CIE space when measuring optical density/intensity (download the ICC profile at rawlight.com/
book_info.html).
2. Using the Color Sampler Tool,
place sampling points on the
brightest significant gray or white
area and darkest areas of the
image. Here only one sampling
point is made on the brightest, sig-
nificant part of the image because
the image contains no significant
blacks.
The color sampling point read-
outs show the Red (R:) and Green
(G:) pixel tonal values at nearly
the same value (R = 159, G = 155).
The blue value, however, is much
lower (B = 122). If any value
contains 255, choose another sam-
pling area.
In longitudinal studies, the color
temperature and tint are set for
an image taken at the first session. This image becomes the reference image for all other images in the
study, as long as the light source is consistent. This reference color temperature and tint would then
be applied to all other images in the study, as long as manual white balancing against a white or gray
card was done at each session.
Note: If 3. The Temperature slider is moved,
adjust- with your eye on the R, G, B read-
ment of the outs. Adjust slider until the R, G,
Temperature and B values in the readouts contain
slider does
the same numeric value (or within
not create a
one point of each other).
match in all
three color
channels--
or becomes The Temperature slider adjusts colors
frustrating to to match the color temperature of the
use--then use light source. The exposure slider is
the eyedrop- equivalent to f-stop settings on cam-
per tool by eras: an adjustment of +1 is similar to
clicking on widening the aperture 1 f-stop.
the eyedrop-
per icon and
then clicking The Tint slider can be moved: it will
on a white add green or magenta overall to the
or light gray
image, depending on the direction in
area in the
which the slider is moved.
image.

4. For exposures within the dynamic range (the histogram doesnt extend beyond the right and left
edges), the Exposure slider is moved until the R, G, B values read at or within one or two points of 240
(for the brightest, significant value).
If black levels are not dark enough, black can be darkened by moving the Black Slider until the darkest
significant black level is at or above a reading of 20.
If the original exposure includes clipped areas (the histogram extends to the right and left edges of the
display, and is cut off): As an aid to determining whether any values have clipped outside of the area

2
you chose for the sampling marker, type O and U to activate graphic overlays: red for clipped high-
lights and blue for clipped black range values. Borders appear around small squares in the top right
and left of the Histogram display to indicate that the graphic overlay has been activated.
The Recovery slider may be used to restore detail in the brightest, significant areas of the image when
these are colored red from the overlay (indicating clipped values). Recovery reconstructs some details
from areas in which one or two channels are clipped to white. Adjust the Recovery slider until the
max R, G, B value reads 240.

If Recovery does not adquately


restore detail in clipped areas of
the image, or after Recovery is
used, an adjustment in Curves
is used to reduce tonal values in
the brightest areas to 240, and
to brighten tonal values in the
darkest areas to a minimum tonal
value of 20.

5. The Fill Light slider can be in-


creased to brighten shadow areas
while retaining blacks. Fill Light
brightens only the darker part of
the image by reconstructing some
details in which one or two color
channels are clipped to black, al-
though it adjusts darker mid tones
as well.

Other sliders that can be used include the Brightness slider. This brightens the image similarly to Expo-
sure, except that Brightness compresses values in the highlights (to avoid clipping) and increases bright-
ness in the shadow areas, completely changing the relationship of grayscale and color tonal values. The
contrast slider can also be used, but it decreases or increases contrast primarily in the mid tones. These
sliders can be used, but the Brightness and Contrast controls may counter other functions, creating data
loss after repeated adjustments. Furthermore, the more valuable contrast adjustment can be done in the
next step with the Clarity function.

3
Before Clarity Adjustment After Clarity Adjustment
6. The Clarity slider can be adjusted to increase contrast in the mid tone region, where it is often most
necessary for publication. This function uses the image itself to make a mask on which to apply the
mid tone contrast adjustment. The pictures above show before and after Clarity adjustments.
Zoom is set to 100% so that display screen pixels are 1:1 with image pixels for the best evaluation.
Image can be zoomed in to 25% to get an idea of how it might reproduce to printed publication. Just
as a larger number of pixels are interpolated to so many dots when printing, so, too, does the screen
interpolate a larger number of pixels to project a smaller number onto the screen.

7. Vibrance and Saturation can also


be adjusted, although Satura-
tion may be best adjusted only
for specific colors, and then to
desaturate (the HSL/Grayscale
tab 4th from the left). Vibrance
differs from Saturation insofar as
it adjusts the saturation so that
clipping is minimized as colors
approach full saturation, chang-
ing the saturation of all lower-
saturated colors with less impact
on the higher-saturated colors
(Photoshop Help text).

8. Using the Luminance function in the HSL/Grayscale tab, the green colors are lightened. Changing the
luminance of a color is probably less necessary for most scientific images versus adjusting Hue and
Saturation, also found in the HSL/Grayscale tabbed area. Alterations to Hue, Saturation and Lumi-
nance work similarly to the Hue/Saturation function in Photoshop. Images can also be converted to
grayscale here, with similar functionality to Black and White in Photoshop.
9. The tabbed Tone Curve (like Curves in Photoshop), Detail (with a more limited Sharpening function
and Noise Reduction), Split Toning (intended for adding color tone to grayscale images), and Lens
Corrections can all be used to further correct the image.
Of particular importance are the Noise Reduction functions within Detail. While these functions are
not as effective as 3rd party noise reduction programs, the corrections are far more efficiently accom-
plished here. Adjust the Luminance slider to reduce noise in the gray channel only (equivalent to the
luminance channel in LAB color mode); or adjust the Color slider to reduce noise in the color channels
(similar to the a and b channels in LAB color mode).
Lens Corrections include correcting Color Fringing due to chromatic aberration at edges of high con-
trast edges of features. Lens vignetting adjustments correct for darkening at edges.

4
9. Save settings if wishing to
apply these to other im-
ages from the same ses-
sion. Use the small, hard
to locate, down arrow
and select Save Settings.
These will be saved as
.xml files. Those files can
be loaded by clicking the
drop down area and se-
lecting Load Settings, or
these can be found in the
last tab named Presets.

10. Save the log file for a record of what you did. Click the drop down list and choose Export Settings to
XMP. This will provide a text file record of all changes made to the image.

Using Adobe Camera Raw with Adobe Bridge


Note that Adobe Camera Raw can be used with Adobe Bridge, the image browsing and database pro-
gram included with the Creative Suite package. To save time, Adobe Camera Raw can be opened in
Adobe Bridge). Once corrections are made, click Done and settings will be remembered when opened in
Photoshop. In addition, the adjustments made in ACR are saved to the metadata (XML) file.
When using Adobe Bridge, you can choose all the files you wish to work on by Shift- or Cntrl-clicking
on a PC or outlining with the mouse on a Macintosh. Right click on a PC and choose Open in Camera
Raw or File>Open in Camera Raw, or use the keys Cntrl/Command + R. Images appear in Adobe Cam-
era Raw on the left side. Choose these one by one to make changes, each time clicking Done after adjust-
ments are made.
To then save the Raw files in another format, such as the TIFF format, use the script Image Processor in
Photoshop (File>Scripts>Image Processor). Select the directory in which files reside, and then choose
the desired file format to save in. Photoshop will parse the entire directory and save all images in your
desired format.

5
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Camera Calibration Information and Links


Several cameras can be matched to a standard by setting color and contrast to the same target
values. Those values are most conveniently set to colors and gray patches provided on a Mac-
beth color chart.

Two websites contain articles on calibration of the kinds of cameras in which Raw file formats
can be obtained. The Creative Pro website:

http://www.creativepro.com/article/out-gamut-calibrating-camera-raw-photoshop-cs

This includes an article written by the late Bruce Fraser. Eric Chan, from MIT, goes over the
procedure in much the same way except for minor differences:

http://people.csail.mit.edu/ericchan/dp/acr-color-match.

Note: Camera calibration can be done on a single camera when interested in mapping colors to a know
standard. Calibration to a known standard isnt necessary, however, when performing colorimetric stud-
ies over time in instances in which changes in color are tracked and recorded. In longitudinal studies,
generally colors are compared with those acquired on day 1, the first image taken in a series. As long as
manual white balancing is done, and a consistent light source used, color variability remains within ac-
ceptable standard deviations (but check against a consistent standard to verify color consistency).

6
Once youve created a satisfactory PDF le, convert it to the appropri-
ate nal format by opening it in Acrobat and choosing File > Save As.
Supplemental Information, Scientific Imaging with
The encapsulated PostScript (EPS) format is preferred for publications
because it retains details in graphics and produces compact les. Also,
Photoshop: Methods, Measurement and OutputEPS les are scalable, meaning that they can be scaled to any dimen-
sions and still retain their inherent resolution, provided that the
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick
graphics are in vector format and the original contains no bitmapped
images. The TIFF format is preferred for bitmapped images, although
JPEG les can be used in word processing documents.

>bV\Zh[gdbi]ZLZWVcYDi]Zg
AdlGZhdaji^dcHdjgXZh
No hard and fast cuto denes a low pixel resolution image versus
an image that is medium or high in resolution. Part of the denition
has to include viewing distance: Nearly all images from image acquisi-
tion devices displayed at less than 60 mm (~2 inches) at the longest
dimension will appear to have enough pixel resolution. The problem
lies with viewing at larger dimensions: When too few pixels make up
an image, individual pixels can be seen. What had once appeared to
be a resolved and detailed image when smaller, appears instead as a
pixilated and aliased image.
This phenomenon is especially true of images from the Web, where
small pixel resolutions are necessary for faster transfer of visual data
over the network. When these images are viewed at larger dimen-
sions, pixilation is evident.
The denition of a low-resolution image can be set at about 400 pixels
or less. But in the end any image with a pixilated appearance and
aliased edges when viewed at the nal size qualies as low resolution.
For that reason, CAT scans on high-resolution lm can be called low-
resolution if pixilation can be seen.
Solutions to pixilation and aliasing problems are listed here:
Aliasing. When aliasing on edges of text and lines in graphic
images is the only problem and pixel coverage is reasonable,
aliased edges can be ameliorated through methods described in
Chapter 6.

B6FL,PJLQGG $0

7
8 = 6 E I : G ) / < : I I > C <  I = :  7 : H I > C E J I )*

;><JG:)#'- K_\@dX^\J`q\[`Xcf^Yfo`eG_fkfj_fgc\]k n`k_g`o`cXk\[fi`^`eXcZ\ek\i Xe[gi`ek\[&jZXee\[`dX^\i`^_k %

Pixilation. Pixilation is a dicult problem to solve because too


little image information is contained in comparatively large pixels
(Figure 4.28, center). Additional image information cant be made
up, so the only alternative is to reduce the eect of the pixilated
appearance. That can be done to varying degrees of success by rst
printing the image to a high-quality inkjet printer as follows:
&# Set the resolution to 150 ppi (typical for true resolution on
inkjet printers regardless of advertised resolutions) in Photo-
shop via the Image Size dialog box (Image > Image Size). Make
sure the Resample Image check box is deselected. Let the
dimensions of the image fall where they will (Figure 4.28, left).
'# Print the image on high-quality photo paper.
(# Scan the image on a atbed scanner at a high enough resolu-
tion to create a le size greater than about 1.5 MB.
)# Open the scanned image in Photoshop. Sharpen it, and set the
contrast and brightness according to the methods described in
Chapters 5 and 6 (Figure 4.28, right).

Efk\1 @]k_\`dX^\`jXgcfk#k_\
mXcl\jZXef]k\eY\jXm\[Xe[k_\e
HXgZZc8VeijgZBZi]dYh
i\dX[\`eXjf]knXi\gif^iXd%@] When at a loss for saving images on the computer screen because
k_Xk`j[fe\n`k_k_\]i\\gif^iXd
>elgcfk#Xe<GJc\ZXeY\jXm\[
they can neither be printed nor saved, the screen can be captured as a
]ifdk_\gcfk% bitmap.

B6FL,PJLQGG $0

8
)+ H 8 > : C I > ; > 8 > B 6 < > C < L > I =  E = D I D H = D E 8 H (

To increase the number of pixels that make up the screen captured


image, do the following:
&# Set the screen resolution as high as possible through the Display
option in the Control Panel.
'# Zoom in on the image until it lls the screen
(# To capture the screen as an image on the Clipboard do one of the
following:
On a Macintosh, press Control+Command+Shift+3. A click like the
sound of a camera shutter lets you know that the image has been
captured..
Efk\1 Jfd\[\[`ZXk\[jZi\\e On a Windows device, press the Print Screen key on the keyboard.
ZXgkli\gif^iXdjXi\XmX`cXYc\Zfd$
d\iZ`XccpXe[gifm`[\dfi\Zfekifc )# Open Photoshop. Choose File > New to open the New dialog box.
fm\in_Xk`jjXm\[\%^%#k_\Zlijfi % The dimensions of your screen capture should be automatically
entered into the Width and Height elds. Click OK.
*# Choose Edit > Paste (or press Ctrl/Command+V).
+# Use the Crop tool to outline the area of interest using methods
described in the section Straighten and Crop, Rotate and Flip in
Chapter 6.
Efk\1 K_\`dX^\n`ccY\gcXZ\[ ,# Save the image in the format of choice.
feXcXp\iXYfm\XYcXeb9XZb^ifle[
cXp\i%N_\ejXm\[XjXK@==fiG_f$
kfj_fgc\#`kn`ccY\jXm\[n`k_cXp$
\ij`ekXZk%Kf\c`d`eXk\cXp\ij#Z_ffj\
CXp\i5=cXkk\eCXp\ij

B6FL,PJLQGG $0

9
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Acquiring for White/Black Values when Ex-


ceeding Dynamic Range
Once manual exposure settings are determined for measuring optical density/intensity (OD/I)
values for a series of sections over a period of time, it is inevitable that a single specimen or
batch of specimens will exceed the dynamic range of the cameras detector. Camera settings
can be changed for specimens that are too bright or too dark, but only according to predeter-
mined changes to the settings.
A chart or graph needs to be made before an acquisition protocol is instituted showing in-
creases and decreases in image density/intensity depending upon exposure (if it is a camera) or
dwell time/power (if it is a laser). In order to make the chart, a reference slide with a constant
transmission (if it is density: a step along the Stouffer step wedge) or emission (if it is fluores-
cence: an area chosen from a fluorescence reference slide) is used.
Start by finding an exposure that creates a midtone value measurement from either a step that
comprises a step wedge for transmission (brightfield) or from a part of a fluorescent reference
slide. That would involve determining an exposure that does not require either high ISO set-
tings (on an SLR camera) or excessive gain. In so doing, poor detection exposures are avoided
where high noise to signal exists. Ideal ISO settings are generally at an ISO of 200 for SLR cam-
eras, and less than a second for scientific digital cameras (depending upon the camera). The
midtone value would be 128 for an 8-bit camera, 2048 for a 12-bit camera and 32,768 for a 16-bit
camera (in the event that the full range of bit depth can be used without interference from
noise). If the acquisition software does not allow for measuring tonal values, then a picture can
be taken, and tonal values can be measured in Photoshop by selecting an area, and then view-
ing the mean pixel value in the Histogram palette (or Histogram dialog box in pre-CS versions
of Photoshop).
A midtone value may be difficult to find with the fluorescent reference slide. When the slide
that matches the wavelength range is chosen (e.g., the blue slide for blue emission), the con-
sequent brightness requires exposure times far shorter than for typical specimens. In order to
compensate for excessive brightness, a mismatched fluorescent reference slide should be used
(e.g., a blue slide for green emission).
Once a midtone value is found, then change the exposure time by increasing and decreasing
the exposure time in 25% increments. For a laser, the dwell time or power can be increased and
decreased by 25% increments, if possible. If not, increase and decrease by existing power incre-
ments. Take a reading from each image and determine the mean density/intensity. Each 25%
increase in power and exposure should result in a 25% increase in the density/intensity up to a
point at which the change will not be linear.
Once these exposures and power adjustments are validated against transmission or fluorescent
emission from a constant sample, then the percentage increase or decrease can be applied to a
set of samples that are outside the dynamic range from a starting point in which fixed settings
are used. The percent increase or decrease in brightness can then be added as a multiple in a
database or spreadsheet program.
For example, lets say that an decrease in exposure of 25% leads to a 25% decrease in the mean
pixel tonal value. After having set up a fixed exposure, suddenly a sample appears in which
the fluorescence is so bright it exceeds the dynamic range of the detector (255 for an 8-bit
camera, 4095 for a 12-bit camera and 65,536 for a 16-bit camera: read as 32,768 in Photoshop CS
versions). So, the exposure is reduced 25% to accommodate the additional brightness. Because
it is a brighter sample in which the exposure is reduced, the value read from the sample needs,
then, to be increased by 25%. The tonal value of the fluorescent emission from that specimen,
then, needs to be increased by 25% in the database/spreadsheet program.
10
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Tools and Functions in Photoshop


At first Photoshop can be visually confusing because of its sheer numbers of options available,
which increase with each update. For scientific imaging, the number of tools, palettes, dialog
boxes, and options is fairly limited. Once you understand which functions are associated with
which tools by reading the following sections, and you practice using these tools, youll become
comfortable with the Photoshop environment.
In the sections that follow many ways to set up preferences for tools and views are described.
Thereafter, locations and functionality of the options bar, the toolbar, menu selections, dialog
boxes and palettes are discussed in detailed. But before describing functions, its important to
understand certain terms: So, some frequently used terms are described first. For the sake of
saving screen space and to show only the most relevant palettes, the number of palettes that ap-
pear (shown in the Window menu) is limited to three or four. Each is explained in this chapter.
Documenting procedures through the use of the History log are also discussed. Documentation
procedures are also included through the use of the History Log

Terms
Before going forward, some Photoshop interface terms need to be defined.
Image window. The image plus the
frame that surrounds it (Figure 1.1).
Selection. The outline created
around regions of interest (ROI). In
Photoshop the selection is animated
and referred to as marching ants.

Figure 1.1 The image window with a rectangular selection.

Palette and drop-down menu. The Layers palette


with its list of options (Figure 1.2). To reveal op-
tions for each palette, click the down arrow at the
upper right.
Layers palette. Images and functions can be
stacked on one another like sheets of paper on
top of the Background layer. In this instance, the
Background layer is a blue-colorized grayscale
image, Layer 1 is green colorized, and Layer 2 is
red colorized; all are separately colorized to show
colocalization/coexistence.
Figure 1.2 Layers palette with drop down
menu.

11
Main menu. The main menu
at the top of the screen (Figure
1.3) allows users to choose
commands from submenus.
For example, to open an image
(or file) from the File menu,
choose File > Open. Figure 5.8 Main menu and selectable features in the options bar.

Submenu or options bar. These headings relate to the tool that is currently being used from the tool-
box, along with some functionality commands.
Toolbox. The tool icons (Figure 5.9); some of which are duplicated as menu
selections in the main menu.
Click and hold the small down arrow to reveal a drop-down menu.

Figure 1.3 Toolbox


and tools with drop
down arrows.

Keyboard commands. Keyboard commands (Figure 1.4)


are shortcuts that include the Ctrl, Shift, and Alt keys on a
Windows computer; Command, Shift, and Option keys on a
Macintosh.

Figure 1.4 Keys from Macintosh (top) and


other computer keyboards (bottom).

Note
The Toolbox and Options Bar
Hold down
the Shift key
Photoshop offers many valuable tools and options. The following list describes Photoshops tools and
when moving their functions as well as some toolbox options.
an object if Click to make the
you want to toolbox two columns
or one column
move one im-
age on a layer Move tool. Use the Move tool to move images, layers, or selections either from within an image
to center it on window or from one image window to another.
another layer.
Marquee tool. The Marquee tool makes rectangular or ellipsoidal selec-
Note
tions around objects (Figure 1.5). When not using other tools, this tool
When using is best selected as the home tool because it wont create artifacts on the image
the Marquee
if you accidentally click with the mouse like the Paint or Fill tool might. Its also
tool, press Figure 1.5 The Marquee
allows for accessing dialog boxes (unlike the Crop tool) when, for example, the
and hold the tool offers four shapes.
Ctrl/Com- Info palette is not available and needs to be displayed.
mand key to Hold down the Shift key and then click and drag with the mouse when you want to make a square or
switch to the circular selection in the image window.
Move tool.
This results Lasso tool. Selections can be made around objects by clicking and dragging the mouse. Selections
in greater start from the tip of the rope tail.
efficiency
Magic Wand tool. The Magic Wand tool automatically selects objects
and reduces
the number
based on similarities in neighboring pixel grayscale values. The range of
of mouse similar pixel values can be specified by the user in the Tolerance box in the options Figure 1.6 The drop
movements bar on an iterative basis. The Magic Wand tool is generally more time consuming down menu offers
needed. than using the Color Range tool from the Select menu, but it can be useful when two tools.
12
Note images contain areas with uniform tones. A Quick Selection tool can be found in the Magic Wand drop
When using down menu (Figure 1.6).
Magic Wand, Quick Selection tool (CS3 only). This tool allows users to set a
one spe- Brush size (a selection with a fixed diameter) from the Brush selec-
cific region
tion drop-down menu in the options bar (Figure 1.7). Use a brush size
of interest
is selected, that is slightly less than the smallest diameter of the feature that will be
and then a included in the selection. This tool finds feature edges far better than the
similar range Magnetic Lasso tool, which is included in the Lasso tool drop-down menu.
of pixel tones When using the Quick Selection tool, first drag the tool close to the border Figure 1.7 Brush selection
are selected
of a feature. If areas outside the border are chosen, ignore them and con- menu used with the Quick
by using the
Modify func- tinue until the feature is surrounded by the selection. Then go to the areas Selection tool.
tions from the in which the selection did not follow the border, hold down the Alt/Option
menu (Select key, and click and drag the mouse over these areas to subtract those parts
> Modify > of the selection.
Similar).
Crop tool. The Crop tool is used to delete all but the highlighted area. This tool does not change
the magnification of the image. Fixed dimensions can be specified in the options bar along with
Note
resolutions, but a change in resolution (by increasing or decreasing the number of pixels that make up the
The Pencil image) is not recommended for ethical reasons: Resolutions are kept at the original value until the image
tool can be needs to be resampled to fit the resolution requirements for each output.
used for
drawing, but Pen and Pen-related tools. These tools are more advanced and are used when drawing and, pos-
drawing or sibly, for image analysis. The Pen tool (top) is used for creating a selection much like a lasso tool,
tracing by only here it is referred to as a path. The Pencil tool (center) and the brush size selected for that
hand cre- tool are used when creating a line along the Pen tools selection (called stroke). The arrow (Path
ates uneven Selection tool [bottom]) is used to select the path and make it active: it is not used to create an ar-
lines. The
row (Use the Line Tool).
Pen tool is
preferred Line tool. The Line tool is used to draw lines, such as scale bars,
for creating and to make arrows. Arrowheads can be added to the Line tool
shapes that by clicking the down arrow next to Weight in the options bar to reveal
cannot be the drop-down menu, and then selecting Start or End (Figure 1.8). Start
created ei- places the arrowhead portion of the line where the arrow first begins. The
ther by using
shape of the arrowhead is specified in Width and Length; Concavity is not
the Line tool
or by using generally used in the sciences. A Width of 400% and a Length of 600% are
the Marquee commonly used arrowhead sizes in biology with Concavity set at 0%. The
tool, such as Weight specifies the thickness of the line. The determination of weight is
a sinusoidal iterative, depending on the pixel resolution of the image. Avoid a Weight Figure 1.8 Arrowhead choices
wave. of 1 or 2 because these weights may disappear in publications. from the Options bar when
Hold down the Shift key to constrain the Line tool to a straight line or to down arrow is clicked.
45 degree, incremental angles.
Note Note tool. Notes can be attached to images as reminders or as a means to communicate informa-
tion about the image to colleagues. Notes do not print to outputs but can be viewed on computer
When a
Note icon displays in Photoshop. Notes can be minimized by clicking the box in the top-right corner. Right-click/
is clicked, Option-click to show the drop-down menu when the cursor is positioned over the note so that it can be
the toolbar deleted, if desired.
automati- Color Sampler tool. For techniques described in this book, the
cally selects
Color Sampler tool provides numeric information that is critical for
the Notes
tool. Any interpreting image corrections. This tool samples parts of the image so
additional that a readout of RGB Color values is shown in the Info palette at points at
clicks on the which the Sampler tool is clicked. The nomenclature, Color Sampler tool, is
image will misleading: Grayscale values can be found as well. The Color Sampler tool Figure 1.9 Menu drop
create more is found with the Eyedropper, Ruler and Count tool (CS3 Extended only) in down list from the Eye-
notes until the drop down menu (Figure 1.9). dropper tool position of
another tool
is selected. Up to four sampling points can be placed on the image. These points are the toolbox.
often placed at the brightest and darkest significant parts of the image:
The word significant is used because some parts of the image may contain
artifacts or noise. The darkest or brightest significant point can simply be
background: For brightfield, that part would be the white area surround-
ing the specimen; for darkfield it would be the dark, featureless part of the
13
Note image. Brightest and darkest significant areas are found by using
The Eyedrop- Levels, which is described later in this chapter.
per tool may Color Sampler points can be averaged over a number of pixels ra-
accidentally diating out from the click point. In earlier versions of Photoshop up
introduce a
to 5 by 5 pixels can be averaged: In CS3 Extended, up to 101 by 101
grayish tone
into white pixels can be averaged. The averaged values can be chosen in the
areas, prob- options bar (Figure 1.10).
ably because Sampling points can be moved by clicking the crosshair and drag-
a grayish part ging. All the points can be cleared (removed) by clicking the Clear Figure 1.10 Drop down menu
of the image showing Color Sampler settings for
button in the options bar, or cleared one by one by clicking and
is clicked averaging pixels.
and a new dragging the icon from the crosshair to the image window.
image is Eyedropper tool. The Eyedropper tool samples click points to change the color of the foreground.
created (File This tool is often mistaken for a tool that borrows from one part of the image, and then transfers
> New) with to another (that would be the Rubber Stamp Tool, which is not ethical for use in science because it makes
Background
spot changes). The Eyedropper tool often appears when contrast and color adjustment tools are used
Color se-
lected in the
because the tool can be placed at different positions on the image and a readout of tonal values can be
New dialog viewed at each position in the Info palette.
box. Avoid Ruler tool. The Ruler tool can be used to find dimensions and angles by clicking at a beginning
clicking on point and at an end point. The lines created by the tool will not print. Numeric values that result
image areas
from using this tool can be read in the Info palette. Hold down the Shift key to constrain the line to a ver-
with this tool
unless there
tical or horizontal, or to 45 degree, incremental angles.
is a specific Count tool. This tool is only available in Photoshop CS3 Extended. It can be used to manually
reason to do count features when automated functions provide incorrect results or when using a computer for
so. stereologic analysis.
Hand tool. The Hand tool is used to move the image (navigate) when zoomed in.
Note
Except when
Zoom tool. This tool zooms in or out (press Alt/Option when clicking). Because the Zoom tool
the Type tool
is active, you
is used so often, it is useful to memorize keyboard commands for zooming in and out. Also, the
can press the keyboard commands provide zoom options when a dialog box is active:
spacebar to Ctrl/Command + zooms in
activate the
Hand tool. Ctrl/Command - zooms out
Double-click Spacebar + Ctrl/Command activates the plus zoom
the Hand tool
to return to Spacebar + Alt/Option activates the minus zoom
100% zoom. Foreground/Background The color of the square on top indicates the foreground color. This col-
or is used for all the tools in the toolbox. The color of the square on the bottom is the background.
This color is used when making a selection and then using the Delete key to eliminate that area,
or when adding to the image. Click the small black and white boxes to return the foreground/
background colors to the default pure black and pure white. Click the double arrow to swap the
foreground and background colors.
Quick Mask. By clicking the Quick Mask icon, the layer becomes a mask, which is used for mask-
ing out parts of the image from the layer below. This method for editing parts of an image (spot
changes) is typical for photographers and graphic designers. Methods in this book do not include mask
methods.
If the mask is clicked, it creates an alpha channel, which is the naming convention for computer functions
that affect transparency and opacity. That channel is stored in addition to the grayscale channel (if the im-
age is grayscale); the red, green, and blue channels (if RGB Color), and so on. If the channel is saved with
a TIFF image, it will likely not open in another program.

Preferences
The Preferences dialog box (Edit > Preferences on Windows; Photoshop > Preferences on Macintosh)
allows users to set a number of parameters. Among them are the views for tools, settings for computer
memory allocation, and settings for logging the correction and conformance steps in Photoshop (History
Log). Grid settings, also in the Preferences dialog box, are discussed in Grids and Guidelines.

14
Units and Rulers
Units of measurement can be set by selecting Preferences > Units & Rulers. Unless the units are set to
pixelsthe unit of measurement for digital imagesthe units will not correlate to the dimensions of the
image except under three conditions:
Images were acquired with a film or flatbed scanner and resolution settings in the Image Size dialog
box in Photoshop were not changed while the Resample box was selected.
Units of measurement were correlated to pixels by selecting Analysis > Set Measurement Scale >
Custom.
The imaging device and associated software provides a correlation of pixels to other units of mea-
surement, and these are embedded in the files description of the image size.

Figure 1.11 An example of rulers surrounding an image on two sides, and


Units drop down menu.

Rulers can be displayed on two sides of the image window (Figure 1.11, left). Activate rulers by choosing
View > Rulers. Right-click/Option-click on the ruler area to quickly change the units to the desired scale
(Figure 1.11, right).

Performance (Memory Usage and Scratch Disks)


The settings for optimal performance of Photoshop can be determined by selecting Preferences > Perfor-
mance (Figure 1.12), or Preferences > Memory and Image Cache in legacy versions of Photoshop.
Memory Usage. Increase the memory allocation setting for
Photoshop if desired, but a higher setting will reduce the
computer resources for other programs running concur-
rently.
Scratch Disks. If the computer is divided into more than
one hard drive, choose the hard drive that does not contain
the Photoshop program and has the most storage space,
and place it at the top.

Figure 1.12 Memory and Scratch Disk


options in Preferences.

History & Cache. History States can be increased or decreased from


the default of 20 to undo more or less steps done in Photoshop (Fig-
ure 1.13). But a higher value also increases the amount of computer
resources necessary to run the program, which can lead to slower
operations in Photoshop.
Cache levels can also be increased or decreased. This refers to images
saved and then displayed at a low resolution (when zoomed out, for ex- Figure 1.13 Options for changing
ample) to speed up operations in Photoshop. the number of remembered steps
and cache levels in History and
Cache.

15
Pre-CS versions of Photoshop took readings from low-resolution files for display in the Histogram palette
when zoomed out. For Pre-CS versions, a cache of 1 is recommended to avoid misreadings, though a
lower cache may interfere with the completion of certain limited routines in Photoshop.
The cache can be kept at the default settings: In Pre-CS versions, when using measurements from the Info
or Histogram palette, make sure the zoom (shown as a percentage at the top of the image window) is at
100% or higher. An exclamation point in CS versions in the Histogram palette may indicate that the cache
has not been refreshed (the low-resolution image is being used instead of the inherent resolution),
which is described later in Histogram Palette.

Image interpolation
Note When images are rescaled to greater dimensions without a compensatory lowering of resolution to keep
Image inter- the same number of pixels, additional pixels need to be created. The opposite occurs when images are
polation set- scaled down. Image interpolation is done to resample the image on greater or fewer numbers of pixels.
tings become Several algorithms for determining color or grayscale pixel values for the new pixels are available in Pref-
the default erences > General (Figure 1.14). The characteristics are grouped as follows:
setting in the
Bicubic. This option samples greater or fewer numbers of
Image Size
dialog box. neighboring pixels to determine the color or grayscale value of
The interpola- new or reduced numbers of pixels. As an added feature, edges
tion selection are anti-aliased to reduce a potentially jagged appearance. Bi-
can also be cubic Smoother further decreases aliasing for smoother edges.
changed in
Nearest Neighbor. This option samples only the immediate
the Image Figure 1.14 Resampling options in
Size dialog neighboring pixels from the original image to determine resul-
the Image Interpolation part of Prefer-
box. tant pixels. This technique preserves edges and is preferred for
ences > General.
resampling images from which quantization is done (but these
images are not resampled before measurements are made,
only afterward for output purposes).
Bilinear. This option works similar to Nearest Neighbor except that the image is read top to bottom
and then side to side. This option may work best with graphics that have been made into bitmaps
(pixels).

History Log
Note The History Log provides a log of corrections and conformance
When setting changes to the image that can be recorded (logged) during sessions
a location for single files (Figure 1.15). The logs can be saved as text files and
for saving can either be saved independently or copied and pasted into the
log files, be Description section of the File Info dialog box (File > File Info) and
sure that it is saved with the image (preferred). Figure 1.15 History log settings
on the hard when desiring to create the most
drive of the If Both and Detailed are selected, and a location is specified for the
detailed log.
computer log file, the beginning and ending time will be recorded along with
in a folder detailed logs of steps performed in Photoshop.
that will not
be erased. Grids and guidelines
Otherwise, Grids or guidelines can be used to line up images for figures or plates along the vertical or horizontal
when Photo-
axis, or to create vertical or horizontal reference lines. The grid can also be used as a method for divid-
shop starts,
a prompt ing the image into smaller areas for quantification purposes. Neither the grid nor the guidelines print to
appears paper (Figure 1.16).
warning that Grid. Set dimensions of the grid in Preferences (Edit > Preferences > Guides, Grid & Slices [Win-
the History dows]; Photoshop > Preferences > Guides, Grid & Slices [Macintosh]). To see the grid, select View >
Log cannot
Show > Show Grid. If pixels have been correlated to another unit of measurement, that unit can be
be located.
specified by placing the value after Gridline every.
Guidelines. Click and drag guidelines from the rulers portion of the image window. The guidelines
will magnetize to the edges of the image, as long as the layer on which the image exists is selected
(see Layers palette later in this chapter). To move the guidelines after they have been placed, hold
down the Ctrl/Command key. When the cursor moves over the guideline, the cursor shape will
change. Click and drag to move the guideline. To clear guidelines one by one, drag a guideline to the
ruler area. To clear all guidelines, select View > Show > Guides (or press Ctrl/Command+H). Select
View > Show > Guides again to show guidelines.
16
Figure 1.16 Using grids and gridlines for statistical methods
and alignment.

Alignment. To auto-position images, users can use the align functions in the Layers palette drop-
down menu, as long as each image is in its own layer and the layers are linked (select Layers > Align).

Palettes
Numerous palettes can be chosen for display when correcting images. For the purposes of this book,
six are most important: Histogram, Info, Layers, History, Action, and Character palettes. Because many
changes require that numeric values be set appropriate to the output, the Histogram and Info palettes in
which these values are displayed need to be visible. Many functions described in this book also require
the use of the Layers palette, so it must be visible as well. The History palette is valuable for going back
20 steps (or more, if the amount is increased in Preferences) when mistakes are made. Actions provide
automation of steps and are invaluable for saving time when imaging and as a means to ensure that steps
are not mistakenly missed. The Character palette provides options for text.
When obtaining readouts, the numeric values used in this book are along the 8-bit scale (0255), even
when images contain 16-bits of information. That may seem counterintuitive, but outputs are generally at
8-bit. Tonal values along the 8-bit range are targeted when performing image corrections.
All palettes can be made visible by selecting them from the Window menu.

Note Histogram palette


The numeric The histogram (Figure 1.17) visually shows the distribution of values from 0255 (8-bit) or 065,535 (16-
readout from bit) along the horizontal (x) axis. The vertical axis (y) of the histogram shows the number of pixels that
the histo- exist in the image at each value.
gram, to date,
does not
show 16-bit
values, even
when they
make up the
image. The
distinction
is important:
When an
image is in
16-bit, the
numeric read-
out cannot
be trusted as
valid, but the
visual display
of the histo-
gram can be
considered Figure 1.17 A histogram display (center) of the image on the left: The drop-down menu shows the Expanded
valid. View selection.
17
Note Drop-down menu. Choose Expanded View and Show Statistics to see numeric values and grayscale
The Histo- or color distribution along the x axis for each channel. Choose Show Channels in Color when work-
gram palette ing with brightfield images to use the histogram as an aid in determining efficacy of color correc-
is not as tions (see Chapter 7, Color Corrections and Final Steps).
useful for
Numeric readouts. Mean, Standard Deviation, Median, and Pixels values are provided based on the
darkfield
images: The selection, either via the Source (the entire image or selected layer) or when a feature in the image is
visual display selected via a selection tool. The Mean, Median, and Standard Deviation refer to the optical density
cannot be or intensity of the selected pixels on a 0255, 8-bit scale. The Pixels value is the sum of all pixels
used to deter- within a selection, or within the image if no selection is made. This value is often used in publica-
mine efficacy tions for obtaining areas.
of correc-
tions to the Readouts when cursor is placed in histogram. The number of pixels at each 8-bit value can be
image. The found by placing the cursor within the histogram. The number of pixels is displayed on the histo-
histogram gram readout as Count at a discrete pixel value (Level). The numbers only correspond to the values
shows mostly in the image when the image is composed of 0255 gray or color values (8-bit). The Percentile indi-
the darker cates the percentage of the total number of the images pixels that exist to the left of the cursor.
values (back-
ground) at
Cache Level. The cache appears as an alert to the user: If the cache
the extreme is 1, the image displayed contains the full pixel resolution. If a
left. The warning with an exclamation point appears at the upper right of
values that the histogram, the cache (a low-resolution display) is being used
make up the and the histogram values do not reflect the inherent pixel distribu-
features are tion of the full-resolution image. Click the circle with arrows at the
virtually non- upper right to uncache the histogram display.
existent on
the display. Channels drop-down menu (Colors). To see all three histograms
However, the for RGB Color images, choose Colors from the drop-down menu
readouts in (Figure 1.18). Luminosity shows grayscale values that compose the
this palette image but excludes colors. Other selections show one channel only. Figure 1.18 Choosing colors
can be useful. from the Histogram palette.
Source. The entire image can be selected to display its histogram
values or only the layer on which the image resides.

Info palette
The Info palette (Figure 1.19) is crucial for determining the degree of correction to images. In this book,
close attention is paid to these numeric readouts, often in conjunction with the use of the Color Sampler
tool. By clicking the small eyedropper icons within the Info palette, several choices can be made concern-
ing the kind of numeric values desired (Figure 1.19, circled).
RGB Color. For purposes of following the methods presented in this book, the most commonly used

Figure 1.19 The


drop-down menu
(left) and read outs
(right) in the Info
palette.

values are RGB Color in 8-bit from 0255.


Grayscale. Grayscale values are indicated by the letter K. These are not grayscale values from 0255;
rather, these values are the consequent percentages of ink deposited on paper if the image was
printed. The larger the value, the darker the measured pixel at the cursor position on the image, and

18
the greater amount of ink used to create the print.
CMYK Color. These are the values used for the amount of ink from each of the four colors (cyan,
magenta, yellow and blacK) that would be deposited on paper if the image was printed (or the per-
centage of transfer when using dye sublimation printers).
16-bit RGB or K values. These are not the true values of features measured in the image; rather,
Note these are values based on calculations done in 15-bit. The result is that all values read out at 1/2 the
inherent value contained in the image. This has been the basis of calculations almost from the incep-
For 32-bit
values, read tion of Photoshop, and those calculations persist in CS3.
outs are deci- Bottom of Info palette. X, y values are the positions of the cursor in relation to the top-left edge,
mal values which reads 0 in x and 0 in y. Values become greater as the cursor moves to the right (x) and toward
from 0 to 1. the bottom (y). W, H values are the width and height of a selection. When selections are outlines of a
complex shape, the width is the longest dimension along the x axis (not through the object), and the
Height is the longest dimension along the y axis.
Additional readouts. When selections are drawn, images are scaled, or the Ruler tool is used. Ad-
ditional readouts appear in the Info palette in place of the second readout:
W, H. Percent change in the width and height when an image is rescaled.
A. Angle of the rotated selection or ruler from its beginning point.
H. Skew of a rectangular selection in degrees.
L. Length of drawing when using the Ruler tool (not shown).
Color Sampler tool readouts. When the Color Sampler tool is clicked on parts of the image, the
readout appears at the bottom of the Info palette (Figure 1.20). The first clicked point is indicated by
#1, the second by #2, and so on to a total of four samples. When adjustments are made by using Lev-
els, Curves, and so on, the value on the left of the slash mark shows the original value and the value
on the right shows the new value after adjustments are made.

Figure 1.20 An image with Color Sampler markings (#1 and #2) and Info palette readouts.

Layers palette
Much of the work in Photoshop is done in layers (Figure 1.21), which are unavoidable. Layers are auto-
matically created by Photoshop for certain tools. Layering opens up additional possibilities when work-
ing with images, but it complicates matters as well. As a general rule, it is worthwhile to remember that
most troubles using Photoshop relate to being on the wrong layer or on a text layer. Keep one eye on the
Layers palette to be sure that the correct layer is chosen when making corrections.
To avoid using layers as much as possible, layers can be flattened by selecting Layers > Flatten Image or
by pressing Ctrl/Command+Shift+E. However, the use of layers is advised so that reediting can occur
later. It is also advised as a way of preserving the original image with nondestructive layers: because
layers are used and altered, the original image that occupies the Background layer is not destroyed.
Background or Smart Object layer. All layers start with a bottommost, Background layer, which is
locked so that changes to it are not possible.
In CS3, the bottommost layer can be a Smart Object (see Chapter 6, Opening Images). This is indicated
by a small icon on the bottom right of the image icon; in this instance, it is next to the text RBC and ques-
tion mark.

19
Figure 1.21 Layer
modes (left), Layer
palette (center) and
Layer drop down
list (right).

Copied layer. The second layer is a duplicate of the first so that it can be edited. It is marked as Copy
Note or Layer 2. This layer is created by clicking the top-right down arrow and choosing Duplicate Layer,
or the Background layer can be dragged into the page icon at the bottom of the Layers palette.
The Layers
palette can Selected layer. The second layer is the selected in Figure 1.21, which is indicated by a dark blue. To
be made select the layer, click the eye icon at the left.
visible or
brought to Adjustment layer. To retain changes made to the contrast or brightness of an image, an adjustment
the front layer can be made above the image layer by clicking the circle icon at the bottom of the Layers palette.
(when Text and lines layers. Layers that contain text are indicated by a capital T. These layers are vector
tabbed and layers, not bitmaps (made of pixels). This means that the vectors must be made into pixelsa pro-
another tool
cess called rasterizingbefore a layer can be merged with another layer. Maintaining vector layers
is visible) by
pressing F7,
is important to keep files small when saving as Acrobat PDF files and to get a better rendition of text
and the Info and lines.
palette by Grouping. The folder icon at the top of the Layers palette indicates that the two layers below have
pressing F8. been grouped. The triangle icon next to the folder can be clicked to hide the two layers below it. Lay-
These short-
ers can be organized into groups and hidden to reduce the complications of working with too many
cut keys are
valuable to
layers.
remember Opacity. Each layer covers the layer below at 100% Opacity. By clicking the triangle adjacent to
for efficien- Opacity and moving the slider, translucence (less opacity) can be introduced.
cy. Pressing
the Tab key Layer mode. The nature of how two (or more) layers blend with each other can be chosen here. This
(when not drop-down menuthough unmarkedprovides choices for the layer blend or mode.
using the Eye icons. Eye icons can be clicked to turn layers on and off. Right-click/Option-click an eye icon to
Type tool)
select either Hide Others to see only the chosen layer or Show Others.
will make
all palettes Delete layer. Layers can be deleted by dragging them to the trash icon or by clicking the top-right
(and the down arrow to reveal the drop-down menu and selecting Delete Layer.
toolbox
invisible/vis- Repositioning a layer. One layer can be moved over another: Click the layer icon and drag a layer
ible. into the desired position.
Renaming a layer. Double-click the existing text and then rename the layer.

History palette
Post-processing steps are saved in the History palette (Figure 1.22), which has a number of options:
Undoing steps. By default, up to 20 steps are recorded. To return to a previous step, click that step.

20
Snapshots. At various points in the image processing
steps, a snapshot can be taken to save all steps to that
point. Steps previous to the snapshot will be merged:
the snapshot saves the image up to the point at which
the snapshot is made.
After saving an image. Once the image is saved, steps
will not be saved with the image. By clicking the
top-right down arrow, an option to save a snapshot
with the image can be selected, but that image will
only open in Photoshop and will not display the steps
used when the image was edited.
Other ways to undo previous steps. Using keystrokes
saves time when undoing previous steps:
Ctrl/Command+Z undoes the previous step.
Ctrl/Command+Alt/Option+Z undoes previous
steps up to the number that is set in the History
panel options. Figure 1.22 An example of steps saved in the
Clicking File > Revert returns the image to the state at History palette.
which it was last saved.

Actions palette
Actions work like macros in scientific software. While editing, actions record steps so that they can be
applied to other images. Actions can be applied to the image that is opened onscreen or, in combination
with the Batch tool (File > Automate > Batch), entire directories of images can have an action applied. An
action can also be made into a droplet (File > Automate > Create Droplet), so that images can be dragged
into the droplet to automatically open Photoshop and have the steps applied. Droplets are very useful in
multiple user facilities because they can be placed on the desktop and users can simply drag image files
into the droplet. The droplet opens Photoshop and performs the action to all files.
A step-by-step protocol for creating the first action, along with additional information, is outlined as fol-
lows (Figure 1.23):

Figure 1.23 The Ac-


tions palette and drop-
down menu.

1. Remove Adobe action set. Before recording an action, remove Adobe s default actions; they are not
needed for steps done in science. In the Actions palette, click on the Default Actions folder. The bar
will turn dark blue. Either drag the default actions to the trash icon at the bottom, or click the upper-
right down arrow and select Delete from the drop-down menu.
2. Create a new set. Before creating an action, specify a Set. Click the upper-right down arrow and
choose New Set. Give the set a name. Add related actions to each set as desired.
3. Create a new action. After naming a set, create an action by choosing New Action from the drop-

21
Note down menu. The action will begin recording, as indicated by the red circle icon. Here youll need to
The open and make a decision. If you prefer a prompt to open an image, then start recording by opening an image.
save steps If an image is mistakenly open already and you want the Open prompt, or if you do not want to in-
are often clude an open step, turn off the Record button by clicking the square icon, close (or open) the image,
excluded in and then click the circle icon to start recording.
actions be-
4. Include duplicate image. Include a duplicate image (Image > Duplicate) as part of the steps to avoid
cause actions
are applied the mistake of saving over an original, raw image. Or create a Smart Object (CS3 only). Select Image >
to more than Duplicate, and then select the original image and close it.
one file. The 5. Record action steps. If you make a mistake, stop recording by clicking the square icon. Undo the pre-
means for vious step(s) by using the History palette or keyboard commands, and drag the incorrect steps from
applying ac-
the actions list to the trash icon. Click the Record button to resume recording. You can select more
tions to more
than one than one action by holding down the Shift key while clicking on the steps to delete.
filethrough 6. Stop Action Recording. When finished, click the square icon to stop recording the actions.
the Batch tool
or Droplets 7. Make steps interactive. Select the check box adjacent to the title of a step to make it interactive. A
include open prompt appears at that step so the user can provide input or make a decision. This is useful when
and save Open is part of the action as well as a Save step. Interactivity is also valuable when you are using an
options. adjustment tool, such as Levels.
8. View an action. Display all action steps by clicking the triangle to the left. The recording also docu-
ments editing steps, much like a History Log.
9. Record again. If you need to change steps, click the step and select Record Again from the drop-down
menu. If you need to add a step after youve made the recording, click on any step and click the Re-
cord icon. After the step is recorded, it is automatically placed at the end of the action. Click and drag
to move the step to the appropriate position among the steps.
10. Play action. Click on the desired action, and then click the triangle at the bottom of the Actions pal-
ette.
11. Make actions into buttons. For convenience, you can convert the title of an action into a button. Then
click the button to play an action. Choose Button Mode from the drop-down menu. Choose Button
Mode again to return the actions to steps. Assign colors to buttons for grouping purposes. You cannot
recording new actions while in Button Mode.
12. Assign a function key. Double-click on the action to access a dialog box. Assign a key to the action so
that when you press the key, the action plays.
13. Save action. Save the action by clicking on the name of the action and selecting Save Actions from the
drop-down menu. You can also convert the action into a droplet as indicated earlier.
14. Insert reminders (Figure 1.24). If you need to add
reminders, click the appropriate steps and add Insert
Stop. These stops display a dialog box in which you
can add comments as prompts or reminders. Select
the Allow Continue check box when the reminder is
not at the end of an action.

Figure 1.24 An example of Insert Stop re-


minder.
Troubleshooting. When steps won t record. If certain steps simply won t record, such as opening the
Histogram palette in pre-CS versions of Photoshop, choose Insert Menu Item from the drop-down menu.
Then select the desired function from the main menu.
Stopping an action while its playing. To stop an action once it has started, press the Escape key in Win-
dows or the Command+period (.) key on a Macintosh to freeze the action at mid-step. To start the action
from the beginning after stopping the action, click the name of the action. When the actions display as
buttons, either change the buttons to a text list and click the name of the action, or create an empty action
with no steps. Click on the empty action, and the desired action button will return to the beginning.
Renaming actions. Double-click on the text portion of the action and rename it.

22
Character palette
Some options for text can be chosen from the options bar, or a greater number of options can be found in
the Character palette (Window > Character). The Character palette not only provides the ability to choose
the typeface (Helvetica, Arial, etc.), its size (8 pt., 10 pt., etc.), and the font style (Bold, Italic, etc.), but also
provides choices for spacing, positioning, and scaling (Figure 1.25):

Leading

Kerning Tracking

Vertical Horizontal
Scaling Scaling
Superscript
Subscript

Figure 1.25 Some


functions of the
Character Palette

Note Leading. The spacing between lines of text (leading) can be set to Auto or to a user-determined
Depending on amount.
the capabil- Kerning. The spacing between letters (kerning) can be set by first clicking in the space between two
ity of video letters and then setting the Kerning amount.
display cards,
text changes Tracking. The space between all letters can be expanded or compressed by changing the tracking.
may not When lettering is small, readability is improved when the spaces between letters are expanded.
appear until
Vertical and Horizontal scaling. The height or width of letters can be scaled to a desired amount.
the image is
zoomed in Superscript, Subscript. Letters, numbers, and symbols can be used to create superscripts and sub-
and then out. scripts.
The font color can also be changed by double-clicking on the Color swatch and choosing from a palette.
When any of these changes are applied to text after it has been typed, be sure to select the text first before
making the changes. It may be difficult to see when a change has been applied onscreen: Click the Mar-
quee tool to complete the change, and then examine the text to see if the change was applied.

Dialog Boxes for Menu Functions


Though several menu functions will be discussed in chapters to follow, the two most important dialog
boxesLevels and Curvesare covered here. Both adjust contrast, brightness, and gamma. Levels can
be thought of as a rough edit and Curves as a fine-tuning feature. The majority of scientific images can be
corrected and/or conformed to outputs through the use of Levels alone. Curves adjustments are appropri-
ate for representative and visualization purposes, for gamma changes, or in other specific instances. Cer-
tain target black and white limits are set in place for both Levels and Curves, and a standard procedure is
used for correcting images.
The Hue and Saturation dialog box is vital for correcting and adjusting colors. Especially when colors
are oversaturateda common occurrence in scientific imagingHue and Saturation settings provide a
means for reducing the saturation.

Levels
The Levels dialog box contains two areas (Figure 1.26). The top portion, the Input Levels, is where exist-
ing gray and color values can be increased (brightened) or decreased (darkened). The bottom area sets
the dynamic range appropriate to the output device with limits set for the blackest and whitest significant
portions of the image. Output Levels provides two slidersone for the white limit and one for the black
limit.

23
Figure 1.26 The
Levels palette is
used to add bright-
ness and contrast,
and to limit tonal
range to gamut of White Output Slider
outputs.
Input Levels, white adjustment. The white triangle (on the right) can be adjusted to the left to incre-
mentally increase all the gray and color pixel tones (Pixel Values: PV) in the image. The formula is as
follows for an 8-bit or 8-bit/channel image:
((PV/WPI) * (255)) = Output value
PV is the existing pixel value of all pixels in the image; WPI is the White Point Input value, shown in
the rightmost white box in the Levels palette; and 255 is the maximum value in an 8-bit image. The
output value is the new value when the white input point changes. The formula only applies to pixel
values in the image that lie between the white input point and 0: All pixel values higher than the
white input point become clipped at a pixel value of 255.
This formula results in brighter values increasing proportionately more than darker values incre-
mentally from the white point input to 0. The white slider stretches (expands) the histogram. Use the
white slider to increase brightness.
Input Levels, black adjustment. The black slider expands the histogram as well, and its value is
shown in the leftmost white box in the Levels palette. Use the black slider to increase contrast by
darkening darker features incrementally more than brighter features. The formula for the black
slider (Black Point Input: BPI) follows:
((PV BPI/255 BPI) * (255)) = Output value
The black slider darkens all values below the black input value to a clipped value of 0.
Output Levels, white triangle slider. This triangle, when moved to the left, provides an upper limit
to pixel values: All pixel values that exist in the image above the white output slider value (White
Point Output: WPO) are reduced to the white output slider value or to values that are less than that
value. The white output slider values are shown in the bottom, white box on the right. The formula
follows when adjusting only the white point output slider:
((WPO/255) * (PV)) = Output value
The result of this formula is a decrease in brighter values, incrementally less to the darkest black. It
provides a dynamic range limit to the maximum white in the image.
Output Levels, black triangle slider. The black output triangle, when moved to the right, decreases
the level of darkness in mostly the dark region of the image incrementally less to the brightest re-
gions. Any value less than the black output slider value (Black Point Output: BPO) is the same as the
slider value or incrementally brighter. It is used to set a limit to the maximum black value, keeping
the maximum significant black within the dynamic range of the output device. Its formula follows:
((255 BPO/255) * (PV)) = (Product + BPO) = Output value
All sliders. When more than one slider is used, the formula is shown as follows:
(((PV BPI) * (WPO BPO)) / (WPI BPI)) + BPO = Output value
The output values that result are rounded off, decimal values. Decimal values can introduce rounding
errors, shown as spikes in histograms.

24
Black, Gray, and White Eyedropper tools. Double-
click each eyedropper to enter numeric values to set
white and black limits (more on limits later in this
chapter) or for other purposes (Figure 1.27). These
limits are then used for automatic color and gray-
scale correction. Double-click the eyedropper icons
and enter white and black values:
White eyedropper values for red, green, and blue:
240.
Black eyedropper values for red, green, and blue: 20.

Figure 1.27 White eyedropper target.


Color channels. Each color channel can be selected
individually by clicking the down arrow next to
Channel (Figure 1.28). These color channels are used
for color correction and are discussed in Chapter 7.

Figure 1.28 Color channel drop-down menu.


Curves
The Curves dialog box (Figure 1.29) provides more precise and local control over the adjustment of pixel
tones and colors. With the exception of gamma corrections, when curves adjustments are done according
to the following methods, results are similar to Levels.

Warning
All gamma
changes
are avoided
entirely for
images
destined for
OD/I mea-
surements,
for images in
which OD/I
measure-
ments have
been made,
and when Figure 1.29 An
the linear example of a gam-
relationship of ma adjustment in
values must Curves.
be preserved.
Brightness, contrast, and setting limits. Move the top point to the left to brighten the image (change
the input values) to get the same result as moving the white input triangle in Levels. Move the top
point down to reduce brightness (change the output values) to get the same result as moving the
black output triangle in Levels.

25
Move the bottom point up to darken mostly shadow values (change the input values) to get the same
result as moving the black input triangle in Levels. Move the bottom point to the left to lighten mostly
shadow values (change the output values) to get the same result as moving the black output triangle.
Gamma. Gamma changes, along with changes to limited pixel ranges of the entire image, are ac-
complished by clicking at any point along the sloped line to bend the line. When moving to the right
or left at the center of the line, the line is bent against its former values, changing the gamma. More
than one point can be created along the line by clicking to place points at specific positions. Points
can be removed by clicking on the point and dragging it to the top or bottom of the line. The Curves
function allows much more freedom to change gamma in specific ways to a limited range of pixels at
similar density/intensity values.
Readouts for gamma changes reflect the change in values at the edit position (represented by the dot)
and all other positions no longer included along the 45 degree original line. All parts of the image
containing pixel tones along the bend are changed (re-assigned or re-mapped) to new tonal values.
Once the new tonal values are assigned (after clicking OK in the Curves dialog box), the change you
made is not stored, unless you made an adjustment layer (Layer > New Adjustment Layer > Curves).
Curve Display Options. Various settings are available for changing the display in CS3.
Show Clipping. Selecting this option is the same as holding down the Alt/Option key in Levels.

Hue and Saturation


Typical color images contain three channels of color: red, green
and blue. However, these channels, or components, do not
provide the only way to divide color and tones: Color compo-
nents can be divided in different ways. One way is according to
the hue (the more exact term for what color exists), which is the
saturation of the color (how pure the hue is) and the lightness
(how dark or bright the tones or hues). This means of dividing a
color image is known as Hue, Saturation, and Lightness (Figure
1.30).
When color is divided in this manner, hues can be adjusted sepa-
rately without affecting the lightness or the saturation. So, too,
with lightness and saturation adjustments: These can be adjusted
without affecting other components. This control over color
Figure 1.30 A model showing Hue, Satu-
provides a way to desaturate colors and conform colors to the
ration, and Lightness color components.
CMYK gamut, and is all done in the Hue and Saturation dialog
box (Figure 1.31).

Figure 1.31 Hue and


Saturation dialog box.

26
Troubleshooting Table 1.1
When users are unfamiliar with Troubleshooting
the workings of Photoshop, it s
useful to know what can cause
frustration along the way. Three
situations limit the ability to per-
form desired tasks in Photoshop:
Having the Type tool active
(its icon selected in the toolbox
and a cursor position clicked).
When this tool is selected, few
main menu functions are avail-
able (menu items are grayed
out).
Being on the wrong layer or
being on a layer other than the
one on which the image exists.
If the layer selected is not the
image layer, adjustment tools
from the main menu will not
operate as expected or at all.
Mistakenly making a tiny se-
lection with the Marquee tool.
Nothing happens when adjust-
ments to the image are made.
Table 1.1 contains a brief list of
many problems.

27
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick
8 = 6 E I : G ,  / 8 D A D G 8 D G G : 8 I > D C H 6 C 9  ; > C 6 A H I : E H )&

HXVaZ7Vgh
The most accurate method for showing the dimensions of features is
to use a scale bar. Another method commonly used in light micros-
copy is the magnication description in the caption, which is an
incorrect multiplication of the magnication of the eyepiece by the
power of the lens. It is incorrect for the following reasons:
The indication of the power for lenses is not absolutely accurate:
In manufacturing, the power can vary slightly.
The magnication to the eye is most likely dierent than the mag-
nication to the camera (the camera eyepiece).
Estimates of magnication do not take into account the size of
reproduction in publication, which also aects magnication.
Thus, the best indicator of size is a scale bar.
NXie`e^1 K_\`dX^\dljkY\ Before a scale bar can be created, the unit of measurement for digital
Xk`kjfi`^`eXcg`o\ci\jfclk`fe%@]k_\ imagespixelsis correlated to the desired unit of measurement.
`dX^\_XjY\\ei\j`q\[lj`e^@dX^\
J`q\n_`c\k_\I\jXdgc\@dX^\Yfo
To do this, use an image of a calibrated scale of a known dimension
nXjj\c\Zk\[#k_\ZXc`YiXk`fen`ccY\ acquired at the same magnication as the specimen image. Alter-
`eZfii\Zk% natively, a feature in the image can be used when the size is known
and it is consistent. The same pixel resolution (number of pixels that
compose an image in x and y) must also be used in all images to which
the calibration is applied. For macrophotography, a ruler can be used.
For microphotography, spatially calibrated slides can be purchased
through microscope sales sta or optical supply companies.
The image of the calibrated ruler or slide is positioned in both the x
and y dimensions (unless a grid) to ensure that the pixels are square.
The pixels can be elongated in one dimension if the camera source is
specically intended for output to video monitors at 4:3 aspect ratios
(this problem can be overcome in CS3 by selecting Square Pixels in
the Open dialog box). In any event, images should be checked once to
be sure pixels are square.
The remaining steps for correlating pixels to the desired unit of mea-
surement follow.
To correlate pixels to the desired units of measurement in CS3
Extended:
&# Open the Measurement Scale dialog box by selecting Analysis >
Set Measurement Scale > Custom. The Ruler tool is activated
automatically.

B6FL,PJLQGG $0

28
)' H 8 > : C I > ; > 8 > B 6 < > C <  L > I = E = D I D H = D E 8 H (

'# Click on the rst point (inside the edge of demarcation) of the
calibration image and drag the Ruler tool to the inside edge
of the second point (Figure 7.21 top, left). The Pixel Length is
shown in the Info palette (Figure 7.21 top, right).
(# In the Logical Length box entry in the Open Measurement dialog
box, enter the known amount.
)# In the Logical Units box entry in the Open Measurement dialog
box, enter the unit of measurement of the calibration image.
*# Save the preset so that this scale bar can be used again for related
images.
To correlate pixels to the desired units of measurement in pre-CS3
versions:
&# Double-click on the ruler area surrounding the image in the image
window (if not visible choose View > Rulers). Set the unit of mea-
surement to Pixels, if not already set.
'# Using the Ruler tool in the toolbox (or Line tool) while holding
down the Shift key to constrain the line to the x or y dimension,
drag the line from the outer edge of the rst measurement point
(inside of demarcation) to the inner edge of the second (Figure
7.21 top, left).
;><JG:,#'& 8ZXc`YiXk`fe^i`[
d\Xjli\[Ypk_\Ilc\ikffclgg\i
c\]k #Xg`o\ci\X[flk`ek_\@e]f
gXc\kk\#Xe[XjZXc\YXigcXZ\[fe
k_\`dX^\%

B6FL,PJLQGG $0

29
8 = 6 E I : G ,  / 8 D A D G 8 D G G : 8 I > D C H 6 C 9  ; > C 6 A H I : E H )(

(# Write down the pixels shown for the correlated unit (Figure 7.21
top, right). Be sure to include the pixel dimensions of the image if
they can be chosen on the instrumentation.
To place scale markers on images in CS3 Extended:
&# Choose the correct preset (Analysis > Set Measurement Scale >
saved preset).
'# Create the scale bar automatically using the Place Scale Marker
function (Analysis > Place Scale Marker). The Measurement Scale
Marker dialog box opens.
The Length setting is likely at 1, because it would mimic the length
of the preset.
After clicking OK, a layer group (containing the scale bar and its
text label) is added to the Layers palette and a scale bar appears on
the image.
(# Change the text of the label from Times New Roman (serif type)
to Arial or Helvetica. If a symbol is needed, such as when microns
are the unit of measurement, use Symbol or another typeface for
the appropriate lettering. See the following set of steps for placing
scale markers on images in pre-CS3 for a more detailed description
of this step.
)# Alter the scale bar width by selecting the Marker Graphic layer and
using the Transform tool (Edit > Transform > Scale or press Ctrl/
Command+T). Drag the top-center handle on the transform rect-
angle to enlarge or reduce the width: The cursor will change to a
double arrow.
*# If the scale bar is over light and dark areas, making it dicult to
distinguish, surround the edges with white or black, whichever
is the contrasting color. See the following steps for placing scale
markers on images in pre-CS3 for a more detailed description of
this step (Figure 7.21 bottom).
To place scale markers on images in pre-CS3 versions:
&# Choose the Line tool from the toolbox. In the options bar set the
Weight to a starting value of 10 (this can be changed later).
'# Click the foreground color box (at the bottom of the toolbox) to
select a contrasting color.
(# Make sure the rulers are visible (View > Rulers) and that pixels are
chosen as the units of measurement. If not, right/Control-click
within a ruler and choose Pixels from the context menu.

B6FL,PJLQGG $0

30
)) H 8 > : C I > ; > 8 > B 6 < > C < L > I =  E = D I D H = D E 8 H (

)# While looking at the values in the Info palette, hold down the Shift
key and draw a line until the length matches the calibrated length.
If the line is too thick or too thin, undo the line (Edit > Undo or
Ctrl/Command+Z), reset the Weight, and start to draw again.
*# Enter text to indicate the length. Choose the Type tool from the
toolbox and type above or below the line. If the position of the
text is incorrect, you can reposition it later.
Choose Helvetica or Arial from the Font Family menu on the
options bar unless characters in Greek or another script are added.
Choose Bold from the Font Style menu, if desired.
If two dierent fonts are used (e.g., when including Greek letter-
ing), rst type the desired characters in Arial or Helvetica, and
then when nished, select the character that you want to change
and choose from Font Family menu. If you are using the Symbol
font, increase its size by two or more pixels or points to match the
height of the Arial/Helvetica font.
+# When all the text is entered and styled, select the Move tool and
move the lettering into place.
,# Both the Line tool and Type tool create additional layers. These
can be kept as is, or if you want to reduce the number of layers
and at the same time eliminate vectors (for convenience), merge
the Line and Type tool layers. In the Layers palette, click the eye
icons to turn o all but the line and text layers. Choose Merge Vis-
ible from the Layers palette menu.
-# Link the scale bar to the image by holding down the Shift key and
clicking on the image, the scale bar, and the text layer(s). Then
click the link icon at the bottom of the Layers palette.
Alternatively, you can merge the scale bar and text layers onto the
image layer to ensure that the scale bar will be enlarged or reduced
(scaled) with the image if that occurs in later steps. The disadvan-
tage of this approach is that the scale bar becomes a permanent
part of the image.

H]VgeZc^c\
The use of a sharpening lter is usually delayed until the end of the
correction process. But sharpening doesnt necessarily have to occur
at the end: When problem images are out of focus and critical details
cannot be separated, it can be appropriate to make sharpening cor-
rections on a Smart Object or separate layer as an earlier step, often

B6FL,PJLQGG $0

31
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Saving, Archiving, and Organizing


At this point the image is saved. Generally, this is done before sharpening, changing the gamma, creat-
ing CMYK files, and setting the output resolution (Image Size) because these alterations are specific to
outputs. Exceptions to this rule occur for the following reasons:
When images are too blurry near the beginning of the correction steps and are subsequently sharp-
ened
When gamma correction is necessary to reveal relevant details in darker or brighter regions
When images are made into CMYK Color and then converted back to RGB Color as a means to work
with publication ready images throughout the process.
Images are saved at this juncture as well to preserve the corrected original before using images in figures.
Once individual images are part of a figure, layers are likely to be flattened. A record of corrections along
with the original are lost.
The files are saved in more than one format. While this presents a challenge for storage, it is an unavoid-
able consequence of working with digital images. To date, a universal file format has not been established
across platforms and software manufacturers, and very likely will never be. The ideal file format would
have to be compressed, contain layers or a stack of images, print without font issues, and contain the full
resolution of the original image. Because all these conditions cannot be met in a single format, three or
four formats are created:
Photoshop (.psd) for layered files with correction layers. Save in this format for editing later, if neces-
sary, and for its retention of the original image.
TIFF (.tif) or EPS (.eps) for a nonlayered, more universal format. Save in this format for including in
figures and for its retention of the images original resolution.
JPEG (.jpg) or Portable Network Graphic (.png) for lossy compressed and nonlossy compressed files.
Save in this format for network distribution, inclusion in Microsoft products (Word and PowerPoint
are not made to handle large files), and when required by network administrators.
Acrobat (.pdf) for compressed files. Save in this format for inclusion in electronic submission of
manuscripts, documents, and reports. When files are saved in the .pdf format, a prompt appears.
Images can be further reduced in file size using a JPEG compression: choose maximum setting for
least lossy compression.
If the files are stand-alone images, they are saved to all formats. If they are like most imagesdes-
tined for inclusion in a figurethey are saved only in the Photoshop and TIFF formats. The Photo-
shop format is archived, and the TIFF format is used for subsequent figures (unless a publication
requires that layers be included with images that are part of a figure, a situation that is remote).
Saving as JPEG, PNG, and as an Acrobat PDF file is covered after figures are made in Chapter 8, Sharp-
ening, Gamma, CMYK and Saving Figures. Saving to Photoshop and TIFF formats is described in the
following steps.
To save the corrected image in layers at the original resolution:
1. Save the image as a Photoshop layered file by selecting File > Save. Be sure to choose the .psd format
from the drop-down list. You can also save layered files in the TIFF format, but those files cannot be
opened in other software, and they are generally larger in file size than the Photoshop formatted im-
ages. In addition, the Photoshop format itself, because it has traditionally been the format that saves
with layers, can indicate to users that these are original files with saved corrections.
2. Save the History Log with the name of the image to which the corrections have been applied. It may
not need to be saved, because it is automatically compiled throughout the correction session with a
single image as long as the History Log appears when each new image is opened and a new name is

32
assigned (this is easier to remember when an opening action is created with a History Log prompt,
as discussed earlier).
At this point, the layers can be merged for convenience in handling files (Layer > Flatten Image). If editing
changes are required at a later time, the Photoshop file can be opened and edits can be made. Once the
layers are flattened, the image can be saved as a TIFF file:
1. Choose Layer > Flatten Image.
2. Save as a TIFF file. Be sure Layers is left deselected in the Save dialog box (in case the first step wasnt
taken) and no alpha channels are saved (in case a selection was saved or an alpha channel was created
by accident).
3. Choose LZW compression (a nonlossy compression) from the second dialog box that appears. This
reduces the file size, but the TIFF file will only open in select software programs.

Archiving Files
It is a good idea to create permanent storage on two external disks for archiving the Photoshop and flat-
tened TIFF files. One CD/DVD is kept by the person who created the files, and the other is given to the lab
supervisor or principal investigator. At present, the files are saved to nonrewritable CD or DVD media so
that the files cannot be overwritten.
Deciding on the brand of CD or DVD and which formatting option to use can be confusing. Here are
some suggestions:
Taiyo Yuden media. Taiyo Yuden CDs and DVDs consistently perform better than its competitors
in durability and predicted longevity. While that can change, it is currently the gold standard for
archiving.
-R or +R or R. The denotation of the minus (-), plus (+), and plus, minus before the R (Recordable)
indicates whether or not the disc operates with a Sony device. Sony Corporation, at odds with the
rest of the industry, created its own format. Most legacy devices use the -R format: Choose this for-
mat for DVD media, because newer DVD players from all companies will likely read both formats.
To be on the safe side for CD media, choose the R for universal playback.

Organizing Files
Once the media is supplieda relatively cheap method for storagemeans for organizing files can be
instituted. Within the workgroup, naming conventions can be decided on for those files that remain on
shared hard drives. Keyword searches can then be used to find relevant files.
For images that are found through visual methods, such as the way the Bridge application operates,
thumbnail-sized images, including filenames, have become the convention. While the Browse window
works magnificently for organizing files on a single computer, it cannot be used to organize hard copies
of images or as a way to organize images over the Web (or internally) to share with others.
To create ways to view images with thumbnails and filenames, two methods are described: One is for
making a CD/DVD cover (hard copy), and the other is for creating a Web page in which images can easily
be found. A Web page can also be incorporated into the CD/DVD in the event that large numbers of im-
ages make up the disc. Both can be done with little effort in Photoshop.

To make a CD/DVD cover:


1. Open the Contact Sheet II, automated function (File > Automate > Contact Sheet II) (Figure 1.1).
2. Click the Browse button to identify the pertinent directory. Select (or deselect) Include All Subfolders.
3. In the Document section, set Units to Inches or Millimeters. Set Height and Width to 4.75 inches or
120 mm since a CD/DVD cover is square. Set Resolution to 300 to keep lettering readable. Select the
Flatten All Layers check box because no additional editing needs to be done on the resulting image.
4. In the Thumbnails section include no more than eight columns by eight rows, or images become dif-
ficult to identify. If you are printing to a laserjet, the individual images need to be larger with fewer
columns and rows.
5. Set the Font Size to a minimum of 5 points: Any value less than that creates fonts that are unreadable.

33
Figure 1.1 The Contact Sheet
II dialog box is used for making
CD/DVD covers.

To make a Web/search page:


1. Use the Web Photo Gallery to create a Web or search page. Select File > Automate > Web Photo Gal-
lery (Figure 1.2).
In the Web Photo Gallery window, you can choose several styles for Web pages. Gray Thumb-
nails works well because of its neutral background, but you can use any style.
In the Source Images section, click the Browse button to identify the pertinent directory. Select
(or deselect) Include All Subfolders. The Web page also requires an empty folder for the destina-
tion. You can create that folder after clicking the Destination button.
In the Options section, label the Web site with the indicated options.
2. Click OK.

Figure 1.2 Web Photo


Gallery dialog box (top)
and the completed Web
page (bottom).

When the Web/search page is completed, the Web page appears in the Internet browser (Internet Explor-
er, Safari, Firefox, etc.). Several files and folders are created in the destination directory. All of these files
are kept together so that the entire Web page can operate.
34
The following directions walk you through uploading files to a Web site and placing the file on a CD/DVD.
To upload a Web page to a Web site:
1. Change the name of the index.htm file to a more descriptive name. Do not include dashes, commas,
periods, or slashes in the name and keep it to one word. If the file retains the index.htm name, it will
replace the Web site introductory page (splash page), which is always named index.htm (or index.
html).
2. Once you are connected to the website directory and you are ready to transfer files, you will see all
the existing .htm or .html files (assuming that the website is already operational). Transfer the .htm
and .html files into this directory, along with any other file that is not in the directories that were cre-
ated when you made the web page in Photoshop: Images, Thumbnails and Pages.
If directories already exist in the web page directory with the names Images, Pages and Thumbnails,
do not transfer the same directories to the Web site: Instead, transfer all the images within these
directories to identical directories on the Web site. If any directory does not exist, transfer the whole
directory.
3. Use a Web editing program to create a link to this Web page on the splash page (introductory page).
Otherwise, the page can be accessed by including the name of its .htm file after the name of the Web
site in a URL. For example, if the .htm file is fluvirus.htm and the Web site is FluVirusLab.edu, you
can type http://www.FluVirusLab.edu/fluvirus.htm into the browser window to see the Web page.
To store the file on a CD/DVD:
1. Include the folder in which the Web page exists into the CD/DVD recording software. Rename the
folder if desired.
2. Create a README.txt file within the Web site folder to alert others to the .htm file. This file is clicked
on to activate and display the web page.

35
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Working with Graphs and Tables that Originate


in Microsoft Programs
Challenges to working with graphs and tables can arise because of initial formatting difficul-
ties, loss of resolution, and artifacts introduced into patterns in bars and lines when made from
vector graphics into images. Also, when graphs and tables are re-formatted after insertion into
page layout programs, and formatting is difficult to achieve, then a simple transfer from a vec-
tor graphic to an image can end re-formatting frustration.
If graphs are meant for reproduction as black and white, patterns can be introduced to the
graphs in the graphing program used to create them. If using Excel, after the graph is made
click on bars or lines in the graph and right click to select Format Data Series. In the Format
Data Series dialog box, select the Patterns tab and click on the Fill Effects button. Choose effect
from the Pattern boxes and be sure to set the color (Foreground) as black. Gridlines can also be
removed in Excel by right-clicking on an empty part of the graph and choosing Chart Options.
From the Chart Options dialog box, click on the Gridlines tab and uncheck Major Gridlines.
Resolution loss and loss of formatting can be easily solved by first printing to a pdf file. Be sure
to change the conversion settings to Press Quality (resolution of 1200 dpi) and choose Grayscale
for the mode. You will need to have the professional version of Adobe Acrobat, or pdf conver-
sion software from a 3rd party software company. Formatting should be retained, along with
adequate resolution for publication and posters.
If the file converts in the desired format and no changes need to be made to it, then the docu-
ment can be saved in Acrobat (File>Save As) as a TIFF, JPEG or EPS. The graph or table will be-
come an image file in the TIFF or JPEG formats, but text can be edited if the document is saved
as an EPS file, and the file size will be small (less than a megabyte).
If the file needs to have changes made, it can be opened in Illustrator (if wishing to edit text), or
changes can be made in Photoshop to an image file. The choice depends upon familiarity with
Illustrator, and upon desires to keep formatting and font issues at bay, best accomplished if the
graph or table becomes an image file. If wishing to keep tables and graphs as images, but desir-
ing to make changes to lettering or positioning of text, etc., open the file in Photoshop.
If the file has been saved as a TIFF file in Acrobat, then the file can simply be opened in Pho-
toshop. If, however, the file is a pdf, then, when opening, a dialog box appears requesting
information about the document dimensions and resolution. Choose desired dimensions and a
resolution of 1200 ppi, and choose desired mode (Grayscale or RGB Color). If a resolution less
than 1200 ppi is chosen, some artifacts may be introduced into patterns when graph is made for
black and white reproduction (zoom in to examine for artifacts).
Here are some possible steps for improving images in Photoshop:
If additional white space surrounds the graph, it can be cropped off using Trim
(Image>Trim). This will crop the graph to its border.
Make image into Grayscale: Image>Mode>Grayscale.
Move existing text into different positions by selecting text with the Marquee tool, then
select the Move tool, and click and drag text into new position. Arrow keys can be used
for small increments.
Eliminate text by selecting with the Marquee tool, and then using the Delete key. Remem-
ber that the background color is used when the Delete key is used, so make sure that the
background color is white (press the D key to return to black foreground, white back-
ground).

36
Re-type text by using the Text tool. Choose Arial or Helvetica for lettering and Courier for numbers.
If graphs have to be saved at resolutions lower than 1200 dpi, and patterns have been used in bar
graphs, resample the image (Image>Image Size) to a lower resolution (which will introduce artifacts
in the patterns) and carefully select pattern portions of bars in the graph. Delete existing patterns
(Edit>Clear). While the selection is active, open Patterns.psd file. Find the layer in the Patterns.psd
file with desired pattern, select all (Select>All) and copy (Edit>Copy). Select the graph document
and Paste Into (Edit>Paste Into) selection inside bars. Use the Scale function (Edit>Transform>Scale)
to adjust the size of the pattern.

37
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Alternatives to Layering Image Stacks


As long as images that are part of a stack are separated into component images (versus a file format in
which a single file holds and image stack, such as the DICOM format), the images can be opened in
layers. In CS versions, the means for doing so can be done through a script (File>Script>Load Files into
Stack). The program GIMP (http://gimp-win.sourceforge.net/stable.html) can open TIFF stacks in layers
without making separate component images.
However, the processing time that is taken to apply filters to each layer can be excessive. When filters are
applied, it can be less time consuming to create an action for the filtering, and then apply the filter to each
component TIFF file through Batch processing to entire directories of images.
Before any of this can happen, however, the images need to be saved from formats specific to manufac-
turers (such as the .oib format from Olympus) to TIFF formats. The easiest means for creating TIFF files
from these formats lie in acquisition software for respective manufacturers of devices that make image
stacks. Often, a Save As or Export command will provide a way to save as multiple TIFF files with a
directory for each channel (when necessary). If the TIFF format does not reduce the intrinsic resolution
(often denoted as Display Resolution: the resolution of the screen display), then the Export or Save As
functions can be used to create individual TIFF files from stacks.
When the Export or Save As commands arent used, or when intrinsic resolutions are compromised, then
the free program called Image J (http://rsb.info.nih.gov/ij/download.html) can be used in tandem with
plug-ins available from the University of Wisconsins LOCI facility (http://www.loci.wisc.edu/ome/for-
mats.html) to make component TIFF files. In Image J, saving as component TIFF files is as simple as us-
ing the Save As command, and selecting Image Sequence from the drop down list. In Image J, the size of
the Maximum Memory has to be changed to at least 1000 MB (Edit>Options>Memory...) before attempt-
ing any kind of processing.

Place Images into Folders


After the image stacks are separated into component TIFF files, place images for each channel (red, green,
blue, etc) into its own file folder. Generally, each channel requires its own series of processing steps, and
so you make an action for each channel.
Note that the images should have a name with 001, 002, 003, etc., at the end of each so that the image
stack can be re-assembled in the correct order after processing is done in Photoshop.

Editing Individual TIFF files


Once the component TIFF files are made, then Photoshop can be used to edit each image. Typically with
TIFF files, images need to have noise reduction applied, some kind of brightness and black limit adjust-
ment, and, possibly, an unsharp mask applied. The unsharp mask application may be an adjustment that
needs to be reported in publication. Sometimes an adjustment may also need to be made for adapting
brightness of sections that are deeper into the sample (where more light scatters) to the uppermost sec-
tions (where less light scatters).
For any kind of editing to more than one image in a stack, an action needs to be created using the bright-
est section. For confocal files, the brightest section is typically in the middle of the z-sections. Open this
TIFF section when creating Actions.
Create the action by opening the Actions palette (Window>Actions) and then by creating an action set
(click the down arrow in the upper right of the Actions palette) and choosing first an Action Set and then
an Action. Name these as desired. Once the action is created, the sequence of steps can be recorded.

38
If desiring to remove noise, use Noise Reduction (Filter>Reduce Noise) or the Median filter
(Filter>Noise>Median) to apply a correction. Alternatively, and with greater reduction in noise, use a 3rd
party program (see quickphotoshop.com for more information) to more effectively reduce noise.
For brightness and black limit/white limit adjustments, use Levels to accomplish these corrections as
part of the action. When desiring to match brightness levels to the brightest section (when each z-section
should be equally bright, but light scattering made that impossible), create a duplicate image of the
brightest z-plane and use Color Match action routine to match its histogram to other z-planes.
Once adjustments are applied, then use the Batch command to apply actions to all images in the z-stack.
In the Batch dialog box (File>Automate>Batch) select the Source folder and the destination folder (if de-
sired). Select the action to apply to all TIFF files that make up the image stack.

Returning TIFF Files to an Image Stack


Once an action is made to reduce noise, adjust tones, and, possibly, sharpen images (along with other
adjustments), and that action is applied through a Batch process to every TIFF image for each channel,
the image is returned to an image stack in Image J (or, if possible, in software that came with your confo-
cal). That is done by importing an image sequence (File>Import>Image Sequence). Generally, the image
sequence is auto-determined when you click the first image. However, on Windows, you may have to
select from the last file to the first using the Shift key to force a correct order in stacks (top to bottom).

39
Creating an Action to Process Confocal Images
When you have a bunch of images from Confocal Assistant or similar software, you
.probably want to put them all together into one image, with many layers, yet still be
able to see through the layers a bit. This is a lot of work to do one by one, so here is a
way to do it quickly and easily. This tutorial assumes you are already relatively ac-
quainted with Photoshop and creating and using actions. If you dont know how to
make an action, you might also find our tutorial on creating Actions useful.

First, you need a folder full of TIF images. In


Photoshop, open the first image in the sequence.
Then, under the Image menu, choose dupli-
cate, and click ok for the window that appears.
You now have two images, one a copy of the
other. They will have titles like mri0000.tif and
mri0000 copy. Go back to the original image.

Now go to the Actions palette. Click on the


arrow in the upper right-hand corner and select
New Set from the drop down menu. Enter a
name. After that, go to the menu again, and
select New Action. You can call it what you
like, maybe confocal tif processor or some-
thing.

Remember that your new action will want to


begin recording immediately, and you can con-
trol that with the toolbar at the bottom of the
Actions palette.

Stop
play new new delete
recording start recording
action set action

40
Assuming you do want to keep recording, under the Select menu, choose Select All. Then, under
the Edit menu, choose Copy. After that, close the image (by choosing Close from the File
menu). Now, the only image left open should be the copy image. Under the Edit menu again,
choose Paste. This will paste one image on top of the other one. These two happen to be the same
image, but its ok since the action will put all the images in your folder on top of each other.

Then go to the Layers palette. Make sure you have the top
layer selected, then click on the arrow next to the box where
it says Normal and choose Lighten from the drop down
list. This will allow each layer to be transparent in a way that
will show the layers underneath.

Now, in the Actions palette, stop recording. This is all there is to your action. Now, when you want
to run your action, it is very important that you open the first image in your sequence, and
create a duplicate of it before you use your action. If you forget to do that, the action wont work.

So now to use your action, close the copy image and dont save it. Next, under the File menu,
select Automate and then Batch.

Youll next get a window that looks something like


this. It should already have the action and set selected
for you, if not, just select them from the drop down
boxes. The Source should be Folder, and where it
says Choose, you should choose the folder where
your images are. The Destination should be None.

Once everything is set, click Ok. The action should


proceed. Depending on how many images you have (and
how good your computer is), the process can take a
while. But when its finished, youll have an image with
many layers. You can then either save this as a multi-
layer Photoshop file, or you can flatten the layers (Under
the Layers menu, choose Flatten Image. If the action
doesnt work, make sure you followed all the steps
properly.

41
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Getting Your Inkjet Printer Profiled


Because each inkjet printer may have some variability in its application of color to paper, each
inkjet printer requires a unique profile. A profile can be made after purchasing calibration
equipment, or an agency can do this for you.
A profile is made for each type of paper. You may want to profile only one paper type to
reduce potential errors and mishaps when a printer is used by more than one person. A luster
paper type provides a non-reflective surface and can be a good, all-around paper choice.
Glossy paper is also desirable, especially because this kind of surface may be requested by pub-
lishers to accompany submitted manuscripts.
Here are three inkjet printer profiling service webpages:

http://www.cathysprofiles.com
http://www.inkjetart.com
http://www.wattsdigital.com

From these agencies, you can download color patches that you will print to your paper type.
Be sure to follow their directions carefully when setting printing options in Photoshop: among
these, turn the printers color management off.
Note: The printer/paper combinations these agencies profile are RGB printers. RGB in this instance
is not a reference to the inks used on the printer (which include Cyan, Magenta, Yellow and Black inks),
rather it is a way of distinguishing it from a CMYK printer (printers that require CYMK color conversion
before a print is made). RGB printers do not require that the digital image be converted to CMYK before
printing.

Get Your Monitor Calibrated


All monitors should be calibrated. The equipment for doing this is relatively inexpensive,
and it can be done with little effot. CRT (Cathode Ray Tube) screens are better at revealing the
depth of blacks in reproduction, but these are fast being replaced by flat screens (LCD: liguid
crystal displays) with poor saturation levels in the shadow regions.
For high quality monitors, at the present time the most used monitor by professionals is the
Eizo LCD:

http://www.eizo.com

Calibration devices for LCD, CRT and LCD projection devices can be purchased. However, if
you are in a large city, a professional photography store is recommended for their recommen-
dations. The webpages at Dry Creek Photo are recommended both for background informa-
tion, and for calibration targets to verify calibrations by commercial instruments:

http://www.drycreekphoto.com/Learn/monitor_calibration.htm

Two popular calibration devices are listed below:

http://spyder.datacolor.com/product-mc.php: (Spyder Pro reommended).


http://usa.gretagmacbethstore.com/ (the EyeOne recommended).

42
Calibration Standards
Color standards include a 24 square Macbeth Color Checker and Kodaks Q60 transparency (for rmi-
croscopes). Grayscale standards include the Stouffer step wedges and the Kodak white and gray cards.
Some websites that show the color values and directions on their use include the following:

Color values for the Kodak Q60: http://www.aim-dtp.net/aim/calibration/kodak_q60/index.htm


Color values for the Macbeth color checker: http://www.mambo.net/cgi-bin/TempProcessor/view/113
The Stouffer step wedge web page: http://www.stouffer.net/
Gray and white cards: http://www.rawworkflow.com/products/whibal/index.html

43
Once youve created a satisfactory PDF le, convert it to the appropri-
ate nal format by opening it in Acrobat and choosing File > Save As.
Supplemental Information, Scientific Imaging with
The encapsulated PostScript (EPS) format is preferred for publications
because it retains details in graphics and produces compact les. Also,
Photoshop: Methods, Measurement and OutputEPS les are scalable, meaning that they can be scaled to any dimen-
sions and still retain their inherent resolution, provided that the
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick
graphics are in vector format and the original contains no bitmapped
images. The TIFF format is preferred for bitmapped images, although
JPEG les can be used in word processing documents.

>bV\Zh[gdbi]ZLZWVcYDi]Zg
AdlGZhdaji^dcHdjgXZh
No hard and fast cuto denes a low pixel resolution image versus
an image that is medium or high in resolution. Part of the denition
has to include viewing distance: Nearly all images from image acquisi-
tion devices displayed at less than 60 mm (~2 inches) at the longest
dimension will appear to have enough pixel resolution. The problem
lies with viewing at larger dimensions: When too few pixels make up
an image, individual pixels can be seen. What had once appeared to
be a resolved and detailed image when smaller, appears instead as a
pixilated and aliased image.
This phenomenon is especially true of images from the Web, where
small pixel resolutions are necessary for faster transfer of visual data
over the network. When these images are viewed at larger dimen-
sions, pixilation is evident.
The denition of a low-resolution image can be set at about 400 pixels
or less. But in the end any image with a pixilated appearance and
aliased edges when viewed at the nal size qualies as low resolution.
For that reason, CAT scans on high-resolution lm can be called low-
resolution if pixilation can be seen.
Solutions to pixilation and aliasing problems are listed here:
Aliasing. When aliasing on edges of text and lines in graphic
images is the only problem and pixel coverage is reasonable,
aliased edges can be ameliorated through methods described in
Chapter 6.

B6FL,PJLQGG $0

44
8 = 6 E I : G ) / < : I I > C <  I = :  7 : H I > C E J I )*

;><JG:)#'- K_\@dX^\J`q\[`Xcf^Yfo`eG_fkfj_fgc\]k n`k_g`o`cXk\[fi`^`eXcZ\ek\i Xe[gi`ek\[&jZXee\[`dX^\i`^_k %

Pixilation. Pixilation is a dicult problem to solve because too


little image information is contained in comparatively large pixels
(Figure 4.28, center). Additional image information cant be made
up, so the only alternative is to reduce the eect of the pixilated
appearance. That can be done to varying degrees of success by rst
printing the image to a high-quality inkjet printer as follows:
&# Set the resolution to 150 ppi (typical for true resolution on
inkjet printers regardless of advertised resolutions) in Photo-
shop via the Image Size dialog box (Image > Image Size). Make
sure the Resample Image check box is deselected. Let the
dimensions of the image fall where they will (Figure 4.28, left).
'# Print the image on high-quality photo paper.
(# Scan the image on a atbed scanner at a high enough resolu-
tion to create a le size greater than about 1.5 MB.
)# Open the scanned image in Photoshop. Sharpen it, and set the
contrast and brightness according to the methods described in
Chapters 5 and 6 (Figure 4.28, right).

Efk\1 @]k_\`dX^\`jXgcfk#k_\
mXcl\jZXef]k\eY\jXm\[Xe[k_\e
HXgZZc8VeijgZBZi]dYh
i\dX[\`eXjf]knXi\gif^iXd%@] When at a loss for saving images on the computer screen because
k_Xk`j[fe\n`k_k_\]i\\gif^iXd
>elgcfk#Xe<GJc\ZXeY\jXm\[
they can neither be printed nor saved, the screen can be captured as a
]ifdk_\gcfk% bitmap.

B6FL,PJLQGG $0

45
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Stereology Probes
Several probe overlays for stereology have been made as templates. These templates are at
high resolution, and are available at quickphotoshop.com as a Stereology.zip file (unzipped
to a layered Stereology.psd file). The x, y dimensions of the probes can be matched to desired
dimensions, best done against a calibrated slide when the probe is to be overlayed on digital
images.
For example, if the calibrated size of the grid on a calibrated slide is at a 25 micron width, and
the desired size for the distance for each field measured is 100 microns, the dimensions of a
single probe such as the counting box can be re-sized to fit a 100 micron width. To do that, find
the layer with the counting boxes in the Stereology.psd file and move that layer with the Move
tool to the calibrated slide image. Use the scale function (Edit>Transform>Scale) and hold
down the Shift key while resizing counting boxes to fit a 100 micron square constraint. The
probe may have to be resized, repositioned with the Hand tool and resized again to keep its
place over the calibrated grids.
Alternatively, the probes can be calibrated against known distances, such as the width of a pro-
jected image on a monitor. Simply measure the desired size of the calibrated grid projected on
the screen. Then match the dimensions of the probe to that size.
For example, a 25 micron grid once projected on a screen might comprise 1 inch. If the desired
dimensions for measurement is 100 microns, then the probe needs to extend a distance of 4
inches. Re-size the desired probe, such as the counting probe, to fit 4 inches along the Ruler at
the edge of the image window (Window>Rulers: set ruler units to inches by double clicking in
the ruler area and selecting from the Units drop down list). Print to an inkjet printer to make a
transparency to tape to the front of the monitor. Be sure to retain the resolution setting for the
stereology.psd file.

46
Supplemental Information, Scientific Imaging with
Photoshop: Methods, Measurement and Output
Copyright 2008, Gerald Sedgewick by Jerry Sedgewick

Example of Segmenting and Counting with


Photoshop CS3 Extended
Although this action was created in Photoshop CS3, the steps apply to nearly any version of Photoshop.
The action uses steps that have been included with Photoshop at least back to version 5.0.
Here are the steps:

This image is of yeast colonies in a 35mm plastic dish


grown in an agarose-like substrate. The image was
acquired on a custom stand with a Canon 350D single
lens reflex camera. The camera was modified by hav-
ing the infrared limiting filter removed from in front
of the CCD chip and replaced by an optically clear
window. Thus, the detector captures into the near
infrared (up to the limits of the silicon wafer backing:
1000nm) resulting in a red saturated image when ad-
ditional filtering is not used. Because the image will
be made into grayscale from a channel, additional
filtering was not necessary.

1. This action was begun by opening the Actions pal-


ette (Window>Actions), and making a new set and
a new action from the drop down list. Click on
upper right arrowhead to see the drop down list.
Note that the Begin Recording icon is activated.
That means every step will be recorded as these
are done. It is assumed that one has verified which
steps to take before recording.

47
2. The first steps involve making a selection so that
only the area of interest is outlined. That is done
by using the ellipse selection of the Marquee tool,
and, while holding down the shift key to constrain
the selection to a circle, a rough circle is drawn.
In the Actions menu, this step is called Set Selec-
tion.

3. Because the circular selection will not necessar-


ily align with the relevant part of every 35mm
dish (dishes are placed on a background cutout
with a little wiggle room), and because it is
difficult to center the circular selection, an addi-
tional step is added. The selection is transformed
(Select>Transform Selection). Click and drag on
the box-shaped handles while holding down the
shift key (to maintain circularity) the re-size the se-
lection. By using the arrow keys, the selection can
be centered. Note that the selection does not have
to be sized to include the entire center of the well:
because the final result is a relative comparison of
wells to each other, as long as the same size selec-
tion is used and it is centered by eye, then no bias
will be introduced.

When satisfied, double click inside the selection area, being careful to avoid the centermost icon (used
for aligning purposes) to complete the step. This step can be completed, as well, by clicking on the
Marquee tool and then clicking on Apply when prompted.

4. To add Transform Selection interactively to the ac-


tion, click on the Toggle Dialog On/Off box to add
the interactive icon. This will then allow the user
to move a similarly sized circular selection with
the arrow keys into place, if necessary. Then users
would double click inside the selection when satis-
fied, and the action would continue to the steps
that follow.

5. The channel with the best separation of detail is


isolated by clicking on the undesired channels in
the Channels palette (Window>Channels), and
then deleting the channels by dragging to the Trash
icon, or by right clicking and choosing Delete.

The channel of interest in this example is the green


channel. However, after the Red channel is de-
leted, the image becomes a Multichannel image
and the Green channel becomes Magenta and the
undesired Blue channel becomes Yellow. The Yel-
low channel is also deleted.

This step could also have been done, as described in the book Scientific Imaging with Photoshop:
Methods, Measurement and Output, by splitting the channels and closing the undesired channels.
Split Channels can be found in the drop down list in the Channels palette.

48
6. Change the mode of the image to grayscale
(Image>Mode>Grayscale). In the Actions palette
you can now see that you have 3 additional entries:
Delete red channel, Delete channel Yellow, and
Convert Mode.

7. Here the image is brightened using Levels


(Image>Adjust>Levels). Note that no tonal values
are clipped.

8. In this step, the circular region of interest is placed on a layer above the
original image (background) layer by simply copying (Edit>Copy) and
pasting (Edit>Paste). This is done so that, in subsequent steps when the
layer is binarized (thresholded), the top layer can be compared with the
background layer to determine accuracy. It is also done so that the layer
can be corrected for uneven illumination.

9. The image is tested for the degree of uneven


illumination by using the Threshold tool
(Image>Adjust>Threshold). Though the lighting
is absolutely even from one edge of the image to
the other, both the lens/camera combination, and
anomalies introduced by the substrate and plastic
wells create a situation of uneven illumination.

Cancel out of the Threshold dialog box. This step


will not be recorded as a part of your actions.

10. The image is corrected for uneven illumination by simply using the High Pass filter
(Filter>Other>High Pass). That is followed by a Median filter (Filter>Noise>Median) to reduce noise
introduced by the camera (and High Pass filter), and thresholding (Image>Adjust>Threshold) to isolate
features of interest for subsequent counting.

49
11. The thresholded image is compared with the
background image by zooming in and clicking
on the eye icon in the Layers palette to toggle the
layer on and off. The image shown above shows
red-colorized thresholded areas over individual
colonies. Note that some thresholded features
show more than one colony per feature. These
thresholded areas can be joined together in steps
that follow. The idea here is to see that threshold-
ing did a fairly good job of finding and binarizing
locations of colonies.

The three steps that include High Pass, Median


and Thresholding together create a way to bina-
rize features. The values that are used for each
function have to be tested before an action is
made. For these colonies, a High Pass of 16.5, a
Median of 3 and a Threshold of 126 is used. More
typically a High Pass of less than 5, a Median of 1
and a variable threshold, usually between 125 and
140 is used.

The advantage of a High Pass filter lies in equalizing histograms for specimen to specimen differences.
Depending upon the samples, the threshold tool remains the same, and so user intervention is not
necessary and potential bias is removed.

Note also that manual counting would be a difficult method for identifying colonies. Some individual
colonies are small and lighter in optical density, and these could be missed. Other colonies occur as
more than one connected together, and these, too, might be missed by the human eye.

Another approach may be available with a means to better isolate colonies by staining with a color or
other method, but it wasnt used for these samples.

12. Along with binarized features,


an artifact due to reflections ex-
ists in the image. To eliminate
the reflection area, a selection
is drawn with the Lasso tool
slightly larger than the area of
the reflection. That area is then
filled with white (Edit>Fill:
choose White from Use drop
down list) so that this area isnt
included in the measurement.
Then the selection is deselected
(Select>Deselect).

The elimination of the reflection area only comprises a small part of the sample, and that part of the
sample is not placed in a biased way (no orientation of the sample is consistent). For these reasons,
this area can be eliminated.

13. Next the binarized features are augmented so that small features due
to the inclusion of noise can be eliminated and non-connected fea-
tures for some colonies can be connected. That is done by clicking on
the icon for Layer 1 (binarized layer) while holding down the Cntrl/
Command key. Select all the black, binarized features by using Color
Range (Select>Color Range: choose Shadows from the Select drop
down list).

Then modify the selection by first contracting


(Select>Modify>Contract: a value of 5 is used). In this instance, 5 is

50
selected for Pixels in the Contract dialog box. This will narrow the selection by 5 pixels in the width
and height, in essence de-selecting all features smaller that 5 pixels in width and height.

Next Expand the selection (Select>Modify>Expand: a value of 10 is used). If the value is set correctly,
this will cause non-connected, larger features to connect, depending on how close these lie to each
other. The numeric value depends on the distance at which these are separated.

The result of completing this step may not absolutely reflect what would be counted by eye, but it
should be a reasonable estimate within 3 or 4 counts. These are, after all, estimates of counts, what
would be arrived at by any automated counting system.

14. Now the larger selected areas are filled with


black (Edit>Fill: choose Black from the Use
drop down list); and the smaller features are
eliminated by filling the inverse of the selection
(Select>Inverse) with white (Edit>Fill: choose
White from the Use drop down list).

Deselect to end this step (Select>Deselect).

15. Stop recording the action by clicking on the Stop Playing/Recording, square button in the Actions
palette, unless you wish to also include measurement actions in Photoshop CS3 Extended. Save the
action by selecting the Action Set entry (here it is Colonies.atn) in the Actions palette and then clicking
on the upper right, down arrow in the Actions palette and choosing Save Actions. Save to more than
one location.

When making an action, be sure to test it on other, related specimens in an experimental set. Compare
with the original.

An action can be applied to an entire directory by using the Batch command (File>Automate>Batch). If a
save action has been included, be sure to check Override action Save As commands checkbox when the
Destination is another folder. This prevents the risk of having the image saved over itself with the same
name.
The binarized features can now be measured. But, at this point, for retaining an image for each counted
35mm well, the image is saved. To prevent saving over the original, the following is done: Duplicate
the image (Image>Duplicate), click on the previous image (be sure an entry in the Actions shows up
called Select Previous Document: sometimes this doesnt take and the recording of actions has to be
stopped by clicking the square icon in the Actions palette, re-choosing the duplicate document, and then
clicking the circle, record icon in the Actions palette and selecting the original again), close the original
document and Dont Save. Then, if desired, flatten the duplicate image to eliminate layers (Layers>Flatten
Image).
The duplicate will contain the word Copy in the title as a convenient way to indicate that it contains the
binarized image.
This duplicate can be measured in a 3rd party software program (such as the freeware program, Image J),
if you do not own Photoshop CS3 Extended.
You may want to add a final step to save the image (File>Save). Make this step interactive, otherwise you
run the risk of having the image saved over itself with the same name.
Generally, a close command is also included so that the screen is cleared (File>Close).

51
If using Photoshop CS3 Extended, you can now select the binarized features with Color Range
(Select>Color Range: select Shadows from the Select drop down list). Measure selected areas
(Analysis>Record Measurements) and Export Measurements (In the Measurement Log palette, click Ex-
port Measurements icon and save as a .txt file). Then, delete measurements to clear the Measurement Log
entries by clicking the Trash icon while all entries are selected.
Alternatively, the count can be written down by hand from the top row of numbers.
Note that more than 700 counts will result in a warning that you have reached the maximum number
(Photoshop logs 700 entries maximum). The Count, however, is a total of all features, including those
features that are not logged in the Measurement log box.
Download this action. The action (colonies.atn) and the accompanying image (colony.tif) can be down-
loaded at http://www.quickphotoshop.com/book_info.html.

52
53
)+ H 8 > : C I > ; > 8 > B 6 < > C < L > I =  E = D I D H = D E 8 H (

To increase the number of pixels that make up the screen captured


image, do the following:
&# Set the screen resolution as high as possible through the Display
option in the Control Panel.
'# Zoom in on the image until it lls the screen
(# To capture the screen as an image on the Clipboard do one of the
following:
On a Macintosh, press Control+Command+Shift+3. A click like the
sound of a camera shutter lets you know that the image has been
captured..
Efk\1 Jfd\[\[`ZXk\[jZi\\e On a Windows device, press the Print Screen key on the keyboard.
ZXgkli\gif^iXdjXi\XmX`cXYc\Zfd$
d\iZ`XccpXe[gifm`[\dfi\Zfekifc )# Open Photoshop. Choose File > New to open the New dialog box.
fm\in_Xk`jjXm\[\%^%#k_\Zlijfi % The dimensions of your screen capture should be automatically
entered into the Width and Height elds. Click OK.
*# Choose Edit > Paste (or press Ctrl/Command+V).
+# Use the Crop tool to outline the area of interest using methods
described in the section Straighten and Crop, Rotate and Flip in
Chapter 6.
Efk\1 K_\`dX^\n`ccY\gcXZ\[ ,# Save the image in the format of choice.
feXcXp\iXYfm\XYcXeb9XZb^ifle[
cXp\i%N_\ejXm\[XjXK@==fiG_f$
kfj_fgc\#`kn`ccY\jXm\[n`k_cXp$
\ij`ekXZk%Kf\c`d`eXk\cXp\ij#Z_ffj\
CXp\i5=cXkk\eCXp\ij

B6FL,PJLQGG $0

54

Das könnte Ihnen auch gefallen