23.12.2012 Views

MATLAB Function Reference Volume 1: A - E - Bad Request

MATLAB Function Reference Volume 1: A - E - Bad Request

MATLAB Function Reference Volume 1: A - E - Bad Request

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

2delete<br />

Purpose Delete files or graphics objects<br />

Graphical<br />

Interface<br />

delete<br />

As an alternative to the delete function, you can delete files using the Current<br />

Directory browser. To open it, select Current Directory from the View menu<br />

in the <strong>MATLAB</strong> desktop.<br />

Syntax delete filename<br />

delete(h)<br />

delete('filename')<br />

Description delete filename deletes the named file from the disk. The filename may<br />

include an absolute pathname or a pathname relative to the current directory.<br />

The filename may also include wildcards, (*).<br />

delete(h) deletes the graphics object with handle h. The function deletes the<br />

object without requesting verification even if the object is a window.<br />

delete('filename') is the function form of delete. Use this form when the<br />

filename is stored in a string.<br />

Note <strong>MATLAB</strong> does not ask for confirmation when you enter the delete<br />

command. To avoid accidentally losing files or graphics objects that you need,<br />

make sure that you have accurately specified the items you want deleted.<br />

Examples To delete all files with a .mat extension in the ../mytests/ directory,<br />

See Also dir, type<br />

delete('../mytests/*.mat')<br />

To delete a directory, use !rmdir rather than delete.<br />

!rmdir mydirectory<br />

2-427

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!