How do i convert a 3 variable array to image?
Mostra commenti meno recenti
I have an 1D array of three variable i.e. 0,1,2. I want to convert this array into a image of three different color say red for 0, blue for 1 and green for 2. How can i do this?
Risposta accettata
Più risposte (1)
KSSV
il 29 Ago 2016
N = 100 ;
H(:,:,1) = zeros(N,N) ;
H(:,:,2) = ones(N,N) ;
H(:,:,3) = 2*ones(N,N);
image(H)
Categorie
Scopri di più su Images in Centro assistenza e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
