**discrete_pdf_sample_2d_test**,
a MATLAB code which
calls discrete_pdf_sample_2d(), which
constructs a Probability Density Function (PDF)
from a table of sample data, and then to use that PDF to create new samples.

The computer code and data files described and made available on this web page are distributed under the GNU LGPL license.

discrete_pdf_sample_2d, a MATLAB code which demonstrates how to construct a Probability Density Function (PDF) from a table of sample data, and then to use that PDF to create new samples.

- discrete_pdf_sample_2d_test.m, calls all the tests.
- discrete_pdf_sample_2d_test.sh, runs all the tests.
- discrete_pdf_sample_2d_test.txt, the output file.

**TEST01** computes 1000 samples, based on a 20x20 PDF table
that is heavily biased toward the northwest corner.

- test01.txt, 1000 sample points generated by the program.
- test01.png, a PNG image of the data.

**TEST02** computes 1000 samples, based on a 12x8 PDF table
that is loosely based on the population of counties in Iowa.

- test02.txt, 1000 sample points generated by the program.
- test02.png, a PNG image of the data.