Skip to content

DOC: update usage of randn in io.rst #24148

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

Closed
jorisvandenbossche opened this issue Dec 7, 2018 · 3 comments · Fixed by #24154
Closed

DOC: update usage of randn in io.rst #24148

jorisvandenbossche opened this issue Dec 7, 2018 · 3 comments · Fixed by #24154

Comments

@jorisvandenbossche
Copy link
Member

In the IO page of the docs (https://github.com/pandas-dev/pandas/blob/master/doc/source/io.rst), there are some occurrences of direct calls to randn instead of using the properly imported np.random.randn in full, which makes the examples not reproducible if you only imported import numpy as np.

A PR that replaces randn with np.random.randn would thus be very welcome.

@jorisvandenbossche jorisvandenbossche added this to the Contributions Welcome milestone Dec 7, 2018
@charlesdong1991
Copy link
Member

might because randn has been assigned to np.random.randn at very beginning in the import part? randn = np.random.randn

@jorisvandenbossche
Copy link
Member Author

randn has been assigned to np.random.randn at very beginning in the import part?

Yes, that is the reason it currently works in our docs. But, that import is hidden to the viewer of the docs, and is not a standard numpy import. So therefore we want to fix this, with the goal to be able to remove this randn = np.random.randn

@charlesdong1991
Copy link
Member

ok, i see... i will make a small pr on it...

@jreback jreback modified the milestones: Contributions Welcome, 0.24.0 Dec 9, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants