%% Is Input a Folder
% Check if the input myfile1.txt is a folder. A result of 0 indicates that myfile1.txt is not a folder.

result = isdir('myfile1.txt')

%
% Create the folder myfolder, and then check if myfolder is a folder. A result of 1 indicates that myfolder is a folder.

mkdir myfolder;
result = isdir('myfolder')

% Copyright 2012 The MathWorks, Inc.