[NCO] change variable name, “rename”

cited from here

I often use this command when the axis format of data is difference which CDO cannot recognize.

(ex: the axis name, “X136_360”, can not be recognized in CDO, but “X” can.)


This is handy when you obtain a file with unfortunate choices of variable, dimension, or attribute names.

ncrename -h -O -v old_variable_name,new_variable_name filename.nc

-h: do not add to the history variable
-O: (upper case) overwrite the file.
-d oldname,newname: to change a dimension name
-a oldname,newname: to change an attribute name


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.