packages/vaex-astro/vaex/astro/transformations.py
def add_virtual_columns_proper_motion2vperpendicular(self, distance="distance", pm_long="pm_l", pm_lat="pm_b",
                                                     vl="vl", vb="vb",
                                                     propagate_uncertainties=False,
                                                     radians=False):
    """Convert proper motion to perpendicular velocities.

    :param distance:
    :param pm_long:
    :param pm_lat:
    :param vl:
    :param vb:
    :param cov_matrix_distance_pm_long_pm_lat:
    :param uncertainty_postfix:
    :param covariance_postfix:
    :param radians:
    :return:
    """
    k = 4.74057
    self.add_variable("k", k, overwrite=False)
    self.add_virtual_column(vl, "k*{pm_long}*{distance}".format(**locals()))
    self.add_virtual_column(vb, "k* {pm_lat}*{distance}".format(**locals()))
    if propagate_uncertainties:
        self.propagate_uncertainties([self[vl], self[vb]])
def add_virtual_columns_proper_motion2vperpendicular(self, distance="distance", pm_long="pm_l", pm_lat="pm_b",
                                                     vl="vl", vb="vb",
                                                     propagate_uncertainties=False,
                                                     radians=False):
    """Convert proper motion to perpendicular velocities.

    :param distance:
    :param pm_long:
    :param pm_lat:
    :param vl:
    :param vb:
    :param cov_matrix_distance_pm_long_pm_lat:
    :param uncertainty_postfix:
    :param covariance_postfix:
    :param radians:
    :return:
    """
    k = 4.74057
    self.add_variable("k", k, overwrite=False)
    self.add_virtual_column(vl, "k*{pm_long}*{distance}".format(**locals()))
    self.add_virtual_column(vb, "k* {pm_lat}*{distance}".format(**locals()))
    if propagate_uncertainties:
        self.propagate_uncertainties([self[vl], self[vb]])
Convert proper motion to perpendicular velocities.

    :param distance:
    :param pm_long:
    :param pm_lat:
    :param vl:
    :param vb:
    :param cov_matrix_distance_pm_long_pm_lat:
    :param uncertainty_postfix:
    :param covariance_postfix:
    :param radians:
    :return: