Often when writing mel scripts, we may have a number of settings for our tools and commands. One example would be creating a polygon cube. The default settings for this are stored so that if you close Maya, the next time you open Maya and create a cube; it will use the previous settings.
optionVar is basically a little mel command that allows us to store some tool settings for the next time Maya opens. First off though, if you execute the command
Maya will list all current user options it is storing.