leaf area measuring — R package “EBImage”

July 9, 2012

(This article was first published on Tony's bubble universe » R, and kindly contributed to R-bloggers)

Besides microscopic images in our routine, common photos are frequently taken to measure quantitative plant features, such as leaf area, root length, branch numbers, etc. Scientific software is available for manual processing. For example, to measure the root length, one need to use the cursor to travel along the target, herein the root. Then the software will tell you how many pixels there are between one end of the root to the other. This sounds easy. But when hundreds of files are waiting, you will probably go nuts. And it is hard work for your eyes.
Last time, I applied EBImage to assist in nuclei counting. I’d like to try this R package on some macroscopic phenotyping. Here, I photographed two obviously different-sized leaves. My goal to calculate the ratio of their leaf area. What should I do?

Actually, this task is simpler than nuclei counting, because only two objects need to be taken care of. So, filtering step would be much easier. I use four steps to accomplish this one:

  1. read the image into R using readImage(), then extract the “blue” channel for further processing;
  2. extract the pixel intensities using imageData(), and perform the image reverse;
  3. remove the background containing small intensity values (herein < 0.8), and again adjust the morphological shapes and remove noise;
  4. use computeFeatures() to retrieve the morphological features, including the leaf area, and layout the resulting image.

The resulting image is shown here, in which the leaf area are masked in read and the numbers are the area size in pixels as I didn’t photographing the bar (oops…). However, I get the ratio of leaf area is around 2.1. And the original code is published elsewhere.

Right now, I don’t know how to separate petioles from blades yet. I guess morphological recognition would do the trick. I’d like to dig it more.

To leave a comment for the author, please follow the link and comment on their blog: Tony's bubble universe » R.

R-bloggers.com offers daily e-mail updates about R news and tutorials on topics such as: Data science, Big Data, R jobs, visualization (ggplot2, Boxplots, maps, animation), programming (RStudio, Sweave, LaTeX, SQL, Eclipse, git, hadoop, Web Scraping) statistics (regression, PCA, time series, trading) and more...

If you got this far, why not subscribe for updates from the site? Choose your flavor: e-mail, twitter, RSS, or facebook...

Tags: , , ,

Comments are closed.


Mango solutions

plotly webpage

dominolab webpage

Zero Inflated Models and Generalized Linear Mixed Models with R

Quantide: statistical consulting and training





CRC R books series

Six Sigma Online Training

Contact us if you wish to help support R-bloggers, and place your banner here.

Never miss an update!
Subscribe to R-bloggers to receive
e-mails with the latest R posts.
(You will not see this message again.)

Click here to close (This popup will not appear again)