imshow is not working
13 views (last 30 days)
Execution of script image as a function is not supported:
C:\Users\NEERAJ RH\Dropbox\My PC (DESKTOP-LM8JK3U)\Desktop\major project\experimntation\image.m
Error in images.internal.basicImageDisplay (line 24)
hh = image(cdata, ...
Error in imshow (line 330)
hh = images.internal.basicImageDisplay(fig_handle,ax_handle,...
Error in gauss (line 2)
Jan on 17 Jun 2022
You have created a script called "image.m". This shadows the built-in function image.
Shadowing built-in functions is a serious problem. Trying to avoid such name conflicts is not easy, because many programmers do not know the names of all toolbox functions. Therefore it is safer to store user-defined functions in folders, which are appended to the path:
addpath yourFolder -end
and not to use cd to move the current folder to a folder, which contains M-files.
You have to rename your "image.m" file to let the buil-in image() work again.
See this tool to check for interferences: https://www.mathworks.com/matlabcentral/fileexchange/27861-uniquefuncnames