Article view
lintsampler: Easy random sampling via linear interpolation
Article information
- Publisher
- Free Journal Network
- Publication
- Published 1 October 2024
- Institutions at publication
- University of Edinburgh
- Full text
- Read the article
Countries with citations
No data yet
Usage
Phase 3: not collected yet
Abstract
lintsampler provides a Python implementation of a technique we term 'linear interpolant sampling': an algorithm to efficiently draw pseudo-random samples from an arbitrary probability density function (PDF). First, the PDF is evaluated on a grid-like structure. Then, it is assumed that the PDF can be approximated between grid vertices by the (multidimensional) linear interpolant. With this assumption, random samples can be efficiently drawn via inverse transform sampling (Devroye, 1986).lintsampler is primarily written with numpy (Harris et al., 2020), drawing some additional functionality from scipy (Virtanen et al., 2020). Under the most basic usage of lintsampler, the user provides a Python function defining the target PDF and some parameters describing a grid-like structure to the LintSampler class, and is then able to draw samples via the sample method. Additionally, there is functionality for the user to set the random seed, employ quasi-Monte Carlo sampling, or sample within a premade grid (DensityGrid) or tree (DensityTree) structure.
Citations per year
| Year | Citations |
|---|---|
| 2024 | 0 |
| 2025 | 1 |
| 2026 | 0 |
OpenAlex counts citations by year for the last ten years only, so the total and the list of citing works can include earlier ones.
Works citing this article
OpenAlex counts 1 citation, but the citing work is not listed here yet: citing works are collected from OpenAlex a few at a time, and it lists most, not all, of the citations it counts.
Where its authors are based
Countries of the institutions the article's authors were affiliated to when it was published.
- AUTHORS
- CITATIONS No data yet
- USAGE Phase 3
| Country | Authors |
|---|---|
| United Kingdom | 2 |