Skip to main content

Polars plugin for generating random distributions

Project description

polars-random

Polars plugin for generating random distributions.

Description

polars-random is a Rust plugin for the Polars DataFrame library that provides functionality to generate random numbers through a new expression namespace called "random". It supports generating random numbers from various distributions such as uniform, normal, and binomial.

Installation

To use polars-random, install it using your favourite tool:

uv add polars-random
poetry add polars-random
pip install polars-random

Usage

Here are some examples of how to use the polars-random plugin:

Uniform Distribution

import polars as pl
import polars_random

df = pl.DataFrame({
    "values": [1.0, 2.0, 3.0]
})

random_series = (
    df
    .select([
        pl
        .col("values")
        .random.rand(seed=42)
    ])
)

print(random_series)

Normal Distribution

import polars as pl
import polars_random

df = pl.DataFrame({
    "values": [1.0, 2.0, 3.0]
})

random_series = (
    df
    .select([
        pl
        .col("values")
        .random.normal(mean=0.0, std=1.0, seed=42)
    ])
)

print(random_series)

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

polars_random-0.1.6.tar.gz (78.5 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

polars_random-0.1.6-cp38-abi3-win_amd64.whl (3.7 MB view details)

Uploaded CPython 3.8+Windows x86-64

polars_random-0.1.6-cp38-abi3-win32.whl (3.4 MB view details)

Uploaded CPython 3.8+Windows x86

polars_random-0.1.6-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (4.4 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ x86-64

polars_random-0.1.6-cp38-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl (4.6 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ ppc64le

polars_random-0.1.6-cp38-abi3-manylinux_2_17_i686.manylinux2014_i686.whl (4.7 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ i686

polars_random-0.1.6-cp38-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (4.3 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ ARMv7l

polars_random-0.1.6-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (4.1 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ ARM64

polars_random-0.1.6-cp38-abi3-macosx_11_0_arm64.whl (3.6 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

polars_random-0.1.6-cp38-abi3-macosx_10_12_x86_64.whl (3.9 MB view details)

Uploaded CPython 3.8+macOS 10.12+ x86-64

File details

Details for the file polars_random-0.1.6.tar.gz.

File metadata

  • Download URL: polars_random-0.1.6.tar.gz
  • Upload date:
  • Size: 78.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: maturin/1.8.1

File hashes

Hashes for polars_random-0.1.6.tar.gz
Algorithm Hash digest
SHA256 fd29df20800f90fadf75ff9788265163ceef1371b8ef3e0c013dfbeaf5032a7e
MD5 1aa5aa4cad9c4cd601e459ea25cb1772
BLAKE2b-256 df6edcb81d099fe9f3c434aa81af124a78e88a18bb73cba16fd2551760c57292

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 2e01901834170d007bb523d3388afeb9f0ba149e8a0e59d2de86c16ffdad9701
MD5 674d86484388a94ec16aa01a04204aca
BLAKE2b-256 a37b357cd32d338f2f515690456ffdfaf60126b327aff6e29629dde9c2ce625f

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-win32.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-win32.whl
Algorithm Hash digest
SHA256 a8fc2e6aa96b1b14c8e1b8f96b6c74817e06bd72918c746a4af32688be28f55e
MD5 a195abbbf267c0f09ed2fdce14af0a7a
BLAKE2b-256 31f0a8011e39f391ceaef6cf5381a755ac9f28d63a21f5da3cb595bb343bf8d4

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 366c79400b70ae6b7256964898c880252f64040ddbac2f86d969130b6a27820d
MD5 71ff117a0e3ad14127fd5f8c68fd5104
BLAKE2b-256 b9c7bcd650f4e73f79aa5acb3efbec425d4abc768390027a6aa1226d2277facc

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 c6716ecfb41c1049bd36f69c2dee5df3c9ea40dfb757f66163504f1f1cf417de
MD5 5d412729903c66f6b0fd2dbaf3efc73b
BLAKE2b-256 02f158a096a4a88eb9b50f07b1ebb8b55987dc47c4aa5455ecc0dbe7a7ff43c2

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 23a39d6d1e35f5b17c3360902dcb62564c9f1bccc6bb9f02d0262eae29615a14
MD5 6cad62c613012912a6154d1f6549277f
BLAKE2b-256 cc066f18aecf2feeca5f80ddc18d930711b177733a315c5412a9a67dc2183931

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 0e5dd14e0266c35fcd531de695014681727c038e4f48f888ff06912a983dce37
MD5 415399dd871dfac324a0f8c9689fa6d3
BLAKE2b-256 0c14f28452beca0420426b364a9f8cfc9098d688ebfd8e4c2ae65842bb8682c3

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 040ed7c928bd9b513470a6848bc9c784c563e18faf3f55fe6640e3a539792cb5
MD5 4e75715798a0a0dee6697114efb37935
BLAKE2b-256 6189ea911e59f2cbca27c74dd83d69eb22e32c90d460f4f58b1ccbfaa50911d5

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 41f824356a8bd44e64c47ba4a01786788fd9fe4645764c1fc28f24663ee4a1ec
MD5 845b896797628373c4252240e38f69e5
BLAKE2b-256 4966cbcacf4733a5d3c2f8adc2b92641f836fd380c4eecef4003471599282c27

See more details on using hashes here.

File details

Details for the file polars_random-0.1.6-cp38-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for polars_random-0.1.6-cp38-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 f51668c756b71a7ca4e068a3220c5c6e04f09c985e630a74a04a644b7375f0c0
MD5 2a5d326647c011d7cd567bb7be8b6af8
BLAKE2b-256 58fdef2003cad6cd73943b11e2da97c49dcec1791435d3d0ef996115ca9f083d

See more details on using hashes here.

Supported by

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