Book Image

Image Processing with ImageJ

Book Image

Image Processing with ImageJ

Overview of this book

Digital image processing is an increasingly important field across a vast array of scientific disciplines. ImageJ's long history and ever-growing user base makes it a perfect candidate for solving daily tasks involving all kinds of image analysis processes. Image Processing with ImageJ is a practical book that will guide you from the most basic analysis techniques to the fine details of implementing new functionalities through the ImageJ plugin system, all of it through the use of examples and practical cases. ImageJ is an excellent public domain imaging analysis platform that can be very easily used for almost all your image processing needs. Image Processing with ImageJ will start by showing you how to open a number of different images, become familiar with the different options, and perform simple analysis operations using the provided image samples. You will also learn how to make modifications through ImageJ filters and how to make local measurements using the selections system. You will also find the instructions necessary to record all the steps you perform so they can be saved and re-run on the same image to ensure analysis reproducibility. Finally, you will get to know some different ImageJ plugins and will learn how to implement your own.
Table of Contents (13 chapters)
Image Processing with ImageJ
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Installing macros for easy access


When you write a macro and save it to a file, you can run it easily by navigating to Plugins | Macros | Run..., and then select the file that contains it. However, if you are going to run a macro several times, this can get tiresome. Fortunately, you can install a set of macros for easy access by navigating to Plugins | Macros | Install.... In order to use this command, we first have to give our macro a name. This is done in the following way:

macro "Test macro" {
// The macro code goes inside the curly braces. Nothing else changes.
}

You can have several macros in a file using this naming convention. Variables can be shared between different macros if they are defined outside the macro blocks and are preceded by the var keyword. Functions defined outside a particular macro block can be accessed by any macro in the file.

We will further explain these concepts with the following example:

var common = "I'm a common variable";
// This function can be called by...