MATLAB: Finding pixel location

arraybinarycoordinate systemimage processingImage Processing ToolboxMATLABpixelpixels

In my binary image line segments are displayed in white. I want to find all the locations (pixel coordinates )which contain pixel value 1 (white)? how can i get those pixel coordinates as an array. Please help me

Best Answer

eg
k = rand(10) > .4
STATS = regionprops(k, 'PixelList','PixelIdxList')