How do you deal the third dimension of a 3-d array to individual 2-d arrays?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Right now I have
m =imread(image);
red = im(:,:,1);
green = im(:,:,2);
blue = im(:,:,3);
How do I combine the red = ... green =, blue =... steps into one online?
1 Commento
Stephen23
il 6 Mag 2018
"How do I combine the red = ... green =, blue =... steps into one online?"
Why do you want to do this? Your code now is simple, neat, and efficient: what is your aim?
Risposte (1)
Ameer Hamza
il 5 Mag 2018
Modificato: Ameer Hamza
il 5 Mag 2018
Here is a possible way to do that,
im = num2cell(imread(image), [1 2]);
[red, green, blue] = im{:};
0 Commenti
Vedere anche
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!