Created
October 8, 2014 20:03
-
-
Save tonyfast/8a2bb4752e0cfc55c99f to your computer and use it in GitHub Desktop.
ImAdjust and Normalize N-D Images in Matlab
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| normalize = @(A)( A-min(A(:)) ) ./ ( max(A(:)) - min(A(:)) ) | |
| adjust = @(A)reshape( ... back to original shape | |
| imadjust( ... adjust image | |
| reshape( ... flatten to 2-D image | |
| normalize(A), ... normalize from zero to one | |
| size(A,1), numel(A)./size(A,1))), ... Reshape to 2-D array | |
| size(A) ... Reshape back to original size | |
| ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment