Specify application-defined data
setappdata(h,'name',value) sets application-defined data for the object with handle h. The application-defined data, which is created if it does not already exist, is assigned the specified name and value. The value can be any type of data.
Application-defined data is data that is meaningful to or defined by your application which you attach to a figure or any GUI component (other than ActiveX® controls) through its AppData property. Only Handle Graphics® MATLAB® objects use this property.