You are now following this Submission
- You will see updates in your followed content feed
- You may receive emails, depending on your communication preferences
In the internet I found this files for this purpose :
centaxes.m , centeraxes.m
I read their code and made my version.
example of using my function:
x=[-2*pi:0.1:2*pi];
plot(x,cos(x));
newaxes
OR
x=[-2*pi:0.1:2*pi];
plot(x,cos(x));
newaxes(1,-0.5)
Cite As
Alexander Brodsky (2026). Custom and centered axes for 2D plot (https://in.mathworks.com/matlabcentral/fileexchange/22715-custom-and-centered-axes-for-2d-plot), MATLAB Central File Exchange. Retrieved .
General Information
- Version 1.1.0.0 (1.58 KB)
MATLAB Release Compatibility
- Compatible with any release
Platform Compatibility
- Windows
- macOS
- Linux