code: def meanjr(self,R,z,nsigma=None,mc=True,nmc=10000,**kwargs):
          
          if mc:
              surfmass, vrs, vts, vzs= self._vmomentdensity(R,z,0.,0.,0.,
                                                               nsigma=nsigma,mc=mc,nmc=nmc,_returnmc=True,
                                                               **kwargs)
              return self._jmomentdensity(R,z,1.,0.,0.,
                                             nsigma=nsigma,mc=mc,nmc=nmc,_returnmc=False,
                                             _vrs=vrs,_vts=vts,_vzs=vzs,
                                                               **kwargs)/surfmass
          else: #pragma: no cover because this is too slow; a warning is shown
              return (self._jmomentdensity(R,z,1.,0.,0.,
                                             nsigma=nsigma,mc=mc,nmc=nmc,
                                             **kwargs)/
                      self._vmomentdensity(R,z,0.,0.,0.,
                                              nsigma=nsigma,mc=mc,nmc=nmc,
                                              **kwargs))
docs: NAME:
  
             meanjr
  
          PURPOSE:
  
             calculate the mean radial action by marginalizing over velocity
  
          INPUT:
  
             R - radius at which to calculate this (can be Quantity)
  
             z - height at which to calculate this (can be Quantity)
  
          OPTIONAL INPUT:
  
             nsigma - number of sigma to integrate the velocities over
  
             scipy.integrate.tplquad kwargs epsabs and epsrel
  
             mc= if True, calculate using Monte Carlo integration
  
             nmc= if mc, use nmc samples
  
          OUTPUT:
  
             meanjr
  
          HISTORY:
  
             2012-08-09 - Written - Bovy (IAS@MPIA)