Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/matlab/15.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
MATLAB中RGB的三维双阵列_Matlab_3d_Rgb - Fatal编程技术网

MATLAB中RGB的三维双阵列

MATLAB中RGB的三维双阵列,matlab,3d,rgb,Matlab,3d,Rgb,我有256 x 256 x 3双阵列。如何在Mat-lab中从中创建(RGB)图片。值类似于(3091198610031699)。提前感谢。您可以将矩阵中的值标准化,使其介于0和1之间,然后使用命令imshow: // create a random example of a matrix I = 4000*rand(256, 256, 3); // normalise the values in I for i = 1:3 I(:, :, i) = I(:, :, i)/max(ma

我有256 x 256 x 3双阵列。如何在Mat-lab中从中创建(RGB)图片。值类似于(3091198610031699)。提前感谢。

您可以将矩阵中的值标准化,使其介于0和1之间,然后使用命令
imshow

// create a random example of a matrix
I = 4000*rand(256, 256, 3);

// normalise the values in I
for i = 1:3
    I(:, :, i) = I(:, :, i)/max(max(I(:, :, i)));
end

// display as image
imshow(I, 'InitialMagnification', 'fit')