Method for controlling a machine tool having a work space and machining units arranged therein, in which, based on operating data and based on a stored machine model, the actual machine tool, at least in the region of the work space thereof, is represented on a visualization unit by means of visualization elements as a virtual machine tool having virtual machining units provided in a virtual work space, and the functions of the virtual machining units are represented as virtual functions, wherein a manual interaction is provided, that an association of a function of the machine tool with this manual interaction is provided, and a function data generator unit is used to generate operating data which correspond to the manual interaction, while taking the associated function into account, and these operating data are transmitted to the visualization controller in order to represent, on the visualization unit, using the visualization elements, the function specified by the manual interaction.