-
Notifications
You must be signed in to change notification settings - Fork 377
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 simulation.randomSource. #175
Conversation
Would we add the lcg in d3-random then? d3/d3-random#33 |
We could, or we could do it here as the default value for simulation.randomSource. |
I think it makes more sense in d3-random, but the code is so small it might be better to copy it here and avoid the additional dependency. |
I’ve added it to this PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Created a test in https://observablehq.com/d/0db0d022c48d72da that I will pull in when the tests (#177) are merged
Sorry to bug you, any chance we could get a minor release with this? |
Fixes #121.
TODO Default to a linear congruential generator rather than Math.random?Done!