dirup

Version 1.0.0.0 (1.32 KB) by Karl
Get the relative path string to go up a number of levels in the directory structure.
195 Downloads
Updated 8 May 2013

View License

This is a very simple function to obtain the relative path string to go up a number of levels in the directory structure, starting from the current working directory.

As the filesep() function is used to generate the (relative) path string, this function works equally well on Unix-based and Windows machines.

Cite As

Karl (2026). dirup (https://ch.mathworks.com/matlabcentral/fileexchange/41674-dirup), MATLAB Central File Exchange. Retrieved .

MATLAB Release Compatibility
Created with R2012b
Compatible with any release
Platform Compatibility
Windows macOS Linux
Categories
Find more on Search Path in Help Center and MATLAB Answers
Version Published Release Notes
1.0.0.0