View License

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Highlights from
Level folder string

Be the first to rate this file! 3 Downloads (last 30 days) File Size: 2.29 KB File ID: #40296 Version: 1.1
image thumbnail

Level folder string


Nikolay S. (view profile)


13 Feb 2013 (Updated )

The function returns user chosen level folder name out of path provided.

| Watch this File

File Information

Folder name usually carries some description of the files stored in the folder. However, it is sometimes interesting to use the name of a folder on a higher level. This function returns the string user chosen level folder, eliminating the need to present the whole path in cases it is obsolete.

Required Products MATLAB
MATLAB release MATLAB 8.0 (R2012b)
Tags for This File   Please login to tag files.
Please login to add a comment or rating.
Comments and Ratings (2)
14 Feb 2013 Nikolay S.

Nikolay S. (view profile)

Hi Jan Simon.
Thanks for the comment.
Indeed you're correct. I thought that '.' (dot) is an illegal character in folder name. Apparently I was wrong. I did some fix which works for actual files- uploading it now. For a case where a arbitrary string is used it seems that this function should receive a path to a folder rather then a file until I'll find a way to distinguish between file and folder.
Best wishes!

Comment only
13 Feb 2013 Jan Simon

Jan Simon (view profile)

Even folder names can contain a dot, so it is not a fair limitation to assume, that the existence of a dot means that the input is a file.

Comment only
14 Feb 2013 1.1

Fixed the dot based distinguish between file name and folder name according to a comment.

Contact us