(nfinite, minp, result, ddof)
return ddof_result(count, minp, res, ddof)
Get result of covariance taking into account min periods.
Get result of covariance taking into account min periods.
Get result of covariance taking into account min periods .
def cov_result_or_nan(nfinite, minp, result, ddof):
    """Get result of covariance taking into account min periods."""
    if nfinite < max(1, minp):
        return numpy.nan

    sum_x, sum_y, sum_xy, count = result
    res = (sum_xy - sum_x * sum_y / nfinite) / nfinite

    return ddof_result(count, minp, res, ddof)
def cov_result_or_nan ( nfinite , minp , result , ddof ) : if nfinite < max ( 1 , minp ) : return numpy . nan sum_x , sum_y , sum_xy , count = result res = ( sum_xy - sum_x * sum_y / nfinite ) / nfinite return ddof_result ( count , minp , res , ddof )