handling 12 bit tiffs in EBImage
1
1
Entering edit mode
Rajarshi Guha ▴ 120
@rajarshi-guha-3531
Last seen 8.6 years ago
Hi, I have a collection of 12 bit tiffs that I would like to analyze using EBImage. However, for the images to show via display() I need to convert them to 8 bit (say by using convert on the command line). Is EBImage capable of handling these types of directly? Or do I always need to sale down to 8 bit outside of R? -- Rajarshi Guha NIH Chemical Genomics Center
convert EBImage convert EBImage • 1.2k views
ADD COMMENT
1
Entering edit mode
Gregoire Pau ▴ 310
@gregoire-pau-3274
Last seen 10.3 years ago
Hi Rajarshi, In the TIFF format, 12-bit images are stored in 16-bit. EBImage supports these images but they have to be scaled by a factor of 16 (2^4), to adjust the dynamic range. The following commands should work: > library(EBImage) > x = readImage('image.tiff')*16 > display(x) If the signal is too faint, images have to be rescaled before being displayed, e.g. using normalize(), which performs the linear scaling (x - min(x))/ (max(x) - min(x)). > display(normalize(x)) Hope this helps, Best regards, Greg --- Gregoire Pau EMBL Research Officer http://www.embl.de/~gpau/ Rajarshi Guha wrote: > Hi, I have a collection of 12 bit tiffs that I would like to analyze > using EBImage. However, for the images to show via display() I need to > convert them to 8 bit (say by using convert on the command line). Is > EBImage capable of handling these types of directly? Or do I always > need to sale down to 8 bit outside of R? > >
ADD COMMENT

Login before adding your answer.

Traffic: 326 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6