%!demo
%! ## Plot the PDF of a Burr distribution, with parameters alpha = 1, c = 2, k = 1,
%! ## truncated at [0.5, 2.5] intervals. Generate 10000 random samples from this
%! ## truncated distribution and superimpose a histogram scaled accordingly
%!
%! pd = makedist ("Burr", "alpha", 1, "c", 2, "k", 1)
%! t = truncate (pd, 0.5, 2.5)
%! rand ("seed", 21);
%! data = random (t, 10000, 1);
%!
%! ## Plot histogram and fitted PDF
%! plot (t)
%! hold on
%! hist (data, 100, 50)
%! hold off
%! title ("Burr distribution (alpha = 1, c = 2, k = 1) truncated at [0.5, 2.5]")
%! legend ("Truncated PDF", "Histogram")
%!
%! ## This demonstrates truncating a Burr distribution to a specific range and
%! ## visualizing the resulting distribution with random samples, useful for
%! ## bounded data scenarios.
