cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Try the Materials Informatics Toolkit, which is designed to easily handle SMILES data. This and other helpful add-ins are available in the JMP® Marketplace
ImageToDatatable JSL
JohnPonte
Staff (Retired)

This script shows you how to read in an image in JSL and generate a data table from the image data. This script will generate a row of data from each pixel. Each row will contain red, green, and blue values for the pixel, an intensity value as well as hue, lightness and saturation values.

Comments

Hi John,

I am curious what data type the pixel values are type casted as when the "getPixels" command is used? Is it 32-bit, 64-bit or other? Thanks.

-Nick

JohnPonte

Hi Nick,

If you do something like, {r, g, b} = img << getPixels("rgb"); , you will get 3 matrices (red, green and blue) where the values are in a normalized color space, between 0.0 - 1.0. Using normalized values means you don't have to worry about how many bits.

Hope this helps,

John

 

Recommended Articles