@experimental(as_of="0.4.0")
def permanova(distance_matrix, grouping, column=None, permutations=999):
    sample_size, num_groups, grouping, tri_idxs, distances = _preprocess_input(
        distance_matrix, grouping, column)

    # Calculate number of objects in each group.
    group_sizes = np.bincount(grouping)
    s_T = (distances ** 2).sum() / sample_size

    test_stat_function = partial(_compute_f_stat, sample_size, num_groups,
                                 tri_idxs, distances, group_sizes, s_T)
    stat, p_value = _run_monte_carlo_stats(test_stat_function, grouping,
                                           permutations)

    return _build_results('PERMANOVA', 'pseudo-F', sample_size, num_groups,
                          stat, p_value, permutations)
Even if we do not chroot, we must drop priv.
dataset/ETHPy150Open biocore/scikit-bio/skbio/stats/distance/_permanova.py/permanova--crossover with--dataset/ETHPy150Open daltonmatos/wsgid/tests/unit/cli_test.py/CliTest.test_should_droppriv_if_app_path_is_passed