galpy.df.diskdf.sample¶
- diskdf.sample(n=1, rrange=None, returnROrbit=True, returnOrbit=False, nphi=1.0, los=None, losdeg=True, nsigma=None, maxd=None, target=True)[source]¶
Sample n*nphi points from this disk DF.
- Parameters:
n (int, optional) – Number of desired samples. Default is 1.
rrange (list, optional) – If you only want samples in this rrange, set this keyword (only works when asking for an (RZ)Orbit).
returnROrbit (bool, optional) – If True, return a planarROrbit instance: [R,vR,vT] (default).
returnOrbit (bool, optional) – If True, return a planarOrbit instance (including phi).
nphi (float, optional) – Number of azimuths to sample for each E,L.
los (float, optional) – Line of sight sampling along this line of sight.
losdeg (bool, optional) – If True, los is in degrees (default).
nsigma (int, optional) – Number of sigma to rejection-sample on.
maxd (float, optional) – Maximum distance to consider (for the rejection sampling).
target (bool, optional) – If True, use target surface mass and sigma2 profiles (default).
- Returns:
n*nphi list of [[E,Lz],…] or list of planar(R)Orbits. CAUTION: lists of EL need to be post-processed to account for the
kappa/omega_R discrepancy
- Return type:
list
Notes
2010-07-10 - Started - Bovy (NYU)