docs: def effstim(self,fluxunits='photlam'):
          """Compute :ref:`effective stimulus <pysynphot-formula-effstim>`.
  
          Calculations are done in given flux unit, and wavelengths
          in Angstrom. Native dataset is used.
  
          Parameters
          ----------
          fluxunits : str
              Flux unit.
  
          Returns
          -------
          ans : float
              Effective stimulus.
  
          Raises
          ------
          ValueError
              Invalid integrated flux.
  
          """
          oldunits=self.fluxunits
          self.convert(fluxunits)
          x=units.Units(fluxunits)
          try:
              if x.isDensity:
                  rate=self.integrate()
                  self._fluxcheck(rate)
                  if x.isMag:
                      ans=x.unitResponse(self.bandpass) - 2.5*math.log10(rate)
                  else:
                      ans=rate*x.unitResponse(self.bandpass)
              else:
                  if x.isMag:
                      #its linear unit must be counts
                      self.convert('counts')
                      total=self.flux.sum()
                      self._fluxcheck(total)
                      ans=-2.5*math.log10(total)
                  else:
                      ans=self.flux.sum()
                      self._fluxcheck(ans)
          finally:
              self.convert(oldunits)
              del x
  
          return ans