how can i creat image from data?
5 views (last 30 days)
Farouk Moukaddem on 26 Aug 2016
Refer to the following documentation link for the "mat2gray" command that is used to convert a matrix to a grayscale image:
You will also find an example in the above link that will help you get started with Image Processing applications.
Image Analyst on 26 Aug 2016
Try this (untested):
% In advance, read your text data into three vectors,
% rows and columns and grayLevels. Then...
lastRow = max(rows);
lastCol = max(columns);
grayImage = zeros(lastRow, lastCol, 'uint8');
for k = 1 : length(rows)
grayImage(rows(k), columns(k)) = grayLevels(k);
This assumes that rows and columns are integers.