NRAO Home > CASA > CASA Toolkit Reference Manual
image.rename - Function

1.1.1 Rename the image file associated with this image tool


Description

This function renames the image file associated with the image tool. If a file with name name already exists, you can overwrite it with the argument overwrite; otherwise a fail will result.

Arguments





Inputs

name

The new image file name

allowed:

string

Default:

overwrite

Overwrite target file if it already exists

allowed:

bool

Default:

false

Returns
bool

Example

 
 
"""  
#  
print "\t----\t rename Ex 1 \t----"  
ia.maketestimage(’myimage’,overwrite=T)  
print ia.name(strippath=T)  
#myimage  
ia.rename(’newimage’, overwrite=T)  
print ia.name(strippath=T)  
#newimage  
#  
"""  
 

__________________________________________________________________


More information about CASA may be found at the CASA web page

Copyright © 2016 Associated Universities Inc., Washington, D.C.

This code is available under the terms of the GNU General Public Lincense


Home | Contact Us | Directories | Site Map | Help | Privacy Policy | Search