https://github.com/cicirello/small-sample-experiments
Code and data for experiments for paper "Algorithms for Generating Small Random Samples"
https://github.com/cicirello/small-sample-experiments
random-sampling
Last synced: 7 months ago
JSON representation
Code and data for experiments for paper "Algorithms for Generating Small Random Samples"
- Host: GitHub
- URL: https://github.com/cicirello/small-sample-experiments
- Owner: cicirello
- License: gpl-3.0
- Created: 2024-07-18T20:09:58.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2025-01-06T20:56:57.000Z (about 1 year ago)
- Last Synced: 2025-03-28T04:51:54.284Z (11 months ago)
- Topics: random-sampling
- Language: Java
- Homepage: https://www.cicirello.org/publications/cicirello2024spe.html
- Size: 49.8 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Code to reproduce experiments from: Algorithms for Generating Small Random Samples
Copyright © 2024 Vincent A. Cicirello
This repository contains the code and raw experiment data for the the following journal article:
> Vincent A. Cicirello. 2025. [Algorithms for Generating Small Random Samples](https://www.cicirello.org/publications/cicirello2025spe.html). *Software: Practice and Experience*, 55(2): 298-306, February 2025. doi:[10.1002/spe.3379](https://doi.org/10.1002/spe.3379). Access the [[Full-Text]](https://onlinelibrary.wiley.com/share/author/J3S4KWMDVFFZNMFS9RY5?target=10.1002/spe.3379).
The experiments utilize the [ρμ](https://rho-mu.cicirello.org/) library, version 4.2.0,
which is automatically imported during the build from the [Maven Central
Repository](https://central.sonatype.com/artifact/org.cicirello/rho-mu).
| __DOI__ | [](https://doi.org/10.1002/spe.3379) |
| :--- | :--- |
| __License__ | [](LICENSE) |
## Building
To build the experiments with Maven, execute the following at the command line:
```shell
mvn clean package
```
The requirements for building the experiments is the same as for building
[ρμ](https://rho-mu.cicirello.org/) version 4.2.0. which is Java 17+.
## Running the Experiments
The above builds a `jar-with-dependencies` that is executable, and which will be found
within the target directory, which is created if it doesn't already exist. You can then
run it with the following:
```shell
java -jar target/small-sample-experiments-1.0.0-jar-with-dependencies.jar
```
Note that this will take a couple hours to run in its entirety.
## Data
If you just want to inspect the results from my run, you can find the data
in [results.txt](results.txt).
There is an additional data file, [results-with-rho-mu-4.0.0.txt](results-with-rho-mu-4.0.0.txt),
from earlier runs with ρμ 4.0.0, where the `nextIntTriple` was implemented differently,
and which didn't include reservoir L for comparison. This is the data for the version of the
experiments from earlier preprint versions of the paper.