How can I find a Value with the smallest error in my Matrix?
    3 visualizaciones (últimos 30 días)
  
       Mostrar comentarios más antiguos
    
    Lukas Nuschele
 el 11 de Dic. de 2019
  
    
    
    
    
    Respondida: David Hill
      
      
 el 11 de Dic. de 2019
            Hey,
The code below finds values("Tempvalues") out of a predefined RGB Scale ("RGB"), output "x" shall be the number of the row this value occurs.
How can I find the value of a Matrix "Tempvalue=100x3" within a "RGB=875x3" Matrix with the smallest error if an exact value doesn´t exist in this matrix?
Thanks for you help, if any questions feel free to ask :)
Greetings Lukas
x=0;
for i=1:100
    Tempvalue=RGBTemp(i,:);
    x=find(ismember(RGB,Tempvalue,'rows'));%will give you the column numbers of RGB that match Tempvalue
    if x~=0
        break;
    end
    else % How can i find the value of "Tempvalue" in "RGB" with the smallest error
end
0 comentarios
Respuesta aceptada
Más respuestas (0)
Ver también
Categorías
				Más información sobre Coastal Engineering en Help Center y File Exchange.
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!

