MATLAB: Finding Of Same Values in Matrix same values Hi everbody I have a matrix includes 1724 values, i want to find which elements are same in this matrix (For ex. 25. and 426. values are same etc.) How can i make this? Thanks.. Best Answer What about using unique and a brute force approach:m = randi(10, 1, 100) % Sample data.allValues = unique(m); % Find unique numbers.for k = 1 : length(allValues) thisValue = allValues(k); indexes{k} = find(m == thisValue); fprintf('The number %f is found at indexes : ', thisValue); fprintf('%d ', indexes{k}); fprintf('\n');end% celldisp(indexes) Related SolutionsMATLAB: How to find second largest OR third largest Or any largest value among the columns of a matrix A=rand(7,25)[aa,indices]=sort(A,'descend') MATLAB: Get the column number of the false values in a logical output You can use the find function:N = 50;A = 1:N;B = 1:41;index = ismember(A,B);[row,col] = find(~index);disp(col) 42 43 44 45 46 47 48 49 50 Related QuestionHow to find the index of first n occurrence of each unique value of a matrixSave/load button in guiSort one set of data to correspond to another.How can i transform the result of ”for loop” to a matrix so i can plot it , cause when i plot it after the for loop it’s plot just the final result as a scaler points ! ( like the photo shown below )How to find two arrays of a matrix are equal? and find their location in that matrix??? for example>>> suppose we have a=[1 3 5 6 3 7] how to find which arrays are equal with each other? and find their location??? thank you very muchFinding Min Max Pixels and Co-ordinates from DICOM imagesHow to find a location of a specific value inside a matrices that is 26x7x101 of length
Best Answer