Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add _statistics module containing _normal_dist_inv_cdf #3251

Open
DimitrisJim opened this issue Oct 8, 2021 · 1 comment · May be fixed by #3256
Open

Add _statistics module containing _normal_dist_inv_cdf #3251

DimitrisJim opened this issue Oct 8, 2021 · 1 comment · May be fixed by #3256

Comments

@DimitrisJim
Copy link
Member

@DimitrisJim DimitrisJim commented Oct 8, 2021

This should be relatively easy. _statistics needs to be defined as a built-in module and _normal_dist_inv_cdf should be added as its sole function.

_normal_dist_inv_cdf is pretty straight-forward to implement with the C version being a pretty direct translation from the Python version.

@DimitrisJim
Copy link
Member Author

@DimitrisJim DimitrisJim commented Oct 8, 2021

Basic scaffold for the module (to be placed in stdlib/src):

pub(crate) use _statistics::make_module;

#[pymodule]
mod _statistics {

    #[pyfunction]
    fn _normal_dist_inv_cdf(...) {}
}

it then needs to be exported in stdlib/src/lib.rs in a similar way to other modules.

Loading

aDotInTheVoid added a commit to aDotInTheVoid/RustPython that referenced this issue Oct 8, 2021
@DimitrisJim DimitrisJim changed the title Add _statistics module containing _normal_dist_inv_cd Add _statistics module containing _normal_dist_inv_cdf Oct 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

1 participant