rok commented on issue #47288:
URL: https://github.com/apache/arrow/issues/47288#issuecomment-7345590051

   We could add:
   
   * `random_int`: uniform discrete integers across Arrow integer types 
(reusing the existing generator and `RandomOptions`)
   * `sample_indices`: uniform `uint64` row indices with or without replacement 
(also covers shuffling/permutation when `n == len` and `replace=false`, and 
composes with `take` for arrays, chunked arrays, batches, and tables)
   * Python bindings in `pyarrow.compute`
   
   This would cover sample in Narwhals without NumPy, `dplyr::slice_sample` in 
R (including replace = TRUE), and basic random int/sampling needs in PyArrow. 
We could follow up with random_bytes (FixedSizeBinary) or other distributions 
later if there's interest.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to