Skip to main content

Some useful np.random functions

Project description

Some useful np.random functions

$pip install numpy-choices
from numpy_choices import get_random_floats, get_random_ints, get_random_items_from_list

rand = get_random_items_from_list(
    list(range(1, 20)), size=10, replace=False, p=None, replace_raise=False
)
print(rand)
# [ 6 16 10  2  9  5 12 15  4 19]

print(get_random_ints(low=0, high=20, size=10))
# [ 0 14  3 14  3 11 15  0  4  5]

print(get_random_floats(low=0, high=20, size=10))
# [10.69714652  9.85398014  1.79753204 18.85165542  8.35101616  9.00431022
#   0.04652976  4.05292685 13.6940055   2.25818349]


    

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

numpy_choices-0.10.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

numpy_choices-0.10-py3-none-any.whl (4.7 kB view details)

Uploaded Python 3

File details

Details for the file numpy_choices-0.10.tar.gz.

File metadata

  • Download URL: numpy_choices-0.10.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.13

File hashes

Hashes for numpy_choices-0.10.tar.gz
Algorithm Hash digest
SHA256 71976c605427718fae7b47116b0148eb70c9d6a0241fce9a89ac3a87da3a994c
MD5 5867ff98a4336f390c6e6fd467028954
BLAKE2b-256 84644676dfd135cc965d0c97a4caa6bfe317da635d4f348c450ec56e69e42776

See more details on using hashes here.

File details

Details for the file numpy_choices-0.10-py3-none-any.whl.

File metadata

File hashes

Hashes for numpy_choices-0.10-py3-none-any.whl
Algorithm Hash digest
SHA256 d5d29d7fdb60fdcbc2329fc68d93870da26590deb6cdebdcb9b8737657face44
MD5 004e1e984b6eaaa6299501a9526ae98e
BLAKE2b-256 72881cf923aabf7dc8fc58af7f9ec8050b222b73252dfa6d80a18be56ccd3fd2

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page