axis off
Not working.
function displayResults(filename,hObject, eventdata, handles)
% Open 'filename' file... for reading...
fid = fopen(filename);
for N=6:1:10
imagename = fgetl(fid);
if ~ischar(imagename), break, end % Meaning: End of File...
[x,map]=imread(imagename);
rgb=ind2rgb(x,map);
ax = handles.(sprintf('axes%d', N));
axis off;
image(rgb, 'Parent', ax);
end
guidata(hObject,handles)
Above code results in following output:
I've highlighted axis in above figure. All images I've used is bitmap with bit depth of 8. I don't want those axis, how can I remove that?
Clear Axes and Reset All Axes PropertiesCreate a line plot and set the axis limits. Clear the line plot from the axes and reset all the axes properties to their default values. cla reset resets all properties of the current axes, except for the Position and Units properties.
axis visibility , where visibility is off , turns off the display of the axes background. Plots in the axes still display. The default for visibility is on , which displays the axes background. example. lim = axis returns the x-axis and y-axis limits for the current axes.
Hide the Axis Ticks and Labels From a Plot Using the axis off Command in MATLAB. If you want to hide both the axis ticks and the axis labels, you can use the axis off command, which hides all the axes. For example, let's plot a sine wave and hide its axis ticks and labels using the axis off command.
In the Plot Style Table Editor, Form View tab, select the plot style that you want to delete from the list of plot styles. Click Delete Style. Click Save & Close.
insert the following at the end of each loop:
set(ax, 'Visible','off')
or you can do this once for all axes in the figure:
set(findobj(gcf, 'type','axes'), 'Visible','off')
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With