def plot(self):
<EOL>if not self.button_enabled.is_checked() or len(self) == <NUM_LIT:0>:<EOL><INDENT>self._set_number_of_plots(<NUM_LIT:0>)<EOL>return self<EOL><DEDENT>if not self.combo_autoscript.get_index()==<NUM_LIT:0>:<EOL><INDENT>self.script.set_text(self._autoscript())<EOL><DEDENT>try:<EOL><INDENT>g = _n.__dict__<EOL>g.update(dict(d=self))<EOL>g.update(dict(xlabels='<STR_LIT:x>', ylabels='<STR_LIT:y>'))<EOL>exec(self.script.get_text(), g)<EOL>x = g['<STR_LIT:x>']<EOL>y = g['<STR_LIT:y>']<EOL>if x == None: x = [None]<EOL>if y == None: y = [None]<EOL>if not _spinmob.fun.is_iterable(x[<NUM_LIT:0>]) and not x[<NUM_LIT:0>] == None: x = [x]<EOL>if not _spinmob.fun.is_iterable(y[<NUM_LIT:0>]) and not y[<NUM_LIT:0>] == None: y = [y]<EOL>if len(x) == <NUM_LIT:1> and not len(y) == <NUM_LIT:1>: x = x*len(y)<EOL>if len(y) == <NUM_LIT:1> and not len(x) == <NUM_LIT:1>: y = y*len(x)<EOL>xlabels = g['<STR_LIT>']<EOL>ylabels = g['<STR_LIT>']<EOL>self._set_number_of_plots(len(x))<EOL>self._update_linked_axes()<EOL>if len(x) == <NUM_LIT:0>: return<EOL>for n in range(max(len(x),len(y))-<NUM_LIT:1>,-<NUM_LIT:1>,-<NUM_LIT:1>):<EOL><INDENT>if x[n] is None: x[n] = list(range(len(y[n])))<EOL>if y[n] is None: y[n] = list(range(len(x[n])))<EOL>self._curves[n].setData(x[n],y[n])<EOL>if type(xlabels) in [str,type(None)]: xlabel = xlabels<EOL>elif n < len(xlabels):                xlabel = xlabels[n]<EOL>else:                                 xlabel = '<STR_LIT>'<EOL>if type(ylabels) in [str,type(None)]: ylabel = ylabels<EOL>elif n < len(ylabels):                ylabel = ylabels[n]<EOL>else:                                 ylabel = '<STR_LIT>'<EOL>i = min(n, len(self.plot_widgets)-<NUM_LIT:1>)<EOL>self.plot_widgets[i].setLabel('<STR_LIT:left>',   ylabel)<EOL>self.plot_widgets[i].setLabel('<STR_LIT>', xlabel)<EOL>if xlabel == None: self.plot_widgets[i].getAxis('<STR_LIT>').showLabel(False)<EOL>if ylabel == None: self.plot_widgets[i].getAxis('<STR_LIT:left>')  .showLabel(False)<EOL><DEDENT>self.script.set_colors('<STR_LIT>','<STR_LIT>')<EOL><DEDENT>except: self.script.set_colors('<STR_LIT>','<STR_LIT>')<EOL>return self<EOL>
Sets the internal databox to the supplied value and plots it.
If databox=None, this will plot the internal databox.