class_docstr: Class representing a simple nonlinear least squares model.
docstr: Get iterator from model instance
  
  Returns
  -------
  itor : iterator
      Returns ``self``
docstr_tok: ["Get","iterator","from","model","instance","Returns","--","--","--","-","itor",":","iterator","Returns","``","self","``"]
code: def __iter__(self):
      """Get iterator from model instance
  
      Returns
      -------
      itor : iterator
          Returns ``self``
      """
      if self.theta is not None:
          self.initial = self.theta
      elif self.initial is not None:
          self.theta = self.initial
      else:
          raise ValueError("need an initial estimate for theta")
  
      self._iter = 0
      self.theta = self.initial
      return self
  
file_path: nipy/nipy/algorithms/statistics/models/nlsmodel.py
imports: import numpy
  import numpy.linalg
  from .model import Model
label_desc: Use image node_id 8 for calling the NLSModel obj's underlying member method code with example usage: obj.__iter__() and returns: self