<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Fitting and simulating generalized pareto distribution in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817773#M40386</link>
    <description>&lt;A href="https://blogs.sas.com/content/iml/2018/11/05/fit-pareto-distribution-sas.html" target="_blank"&gt;https://blogs.sas.com/content/iml/2018/11/05/fit-pareto-distribution-sas.html&lt;/A&gt;</description>
    <pubDate>Mon, 13 Jun 2022 12:56:53 GMT</pubDate>
    <dc:creator>Ksharp</dc:creator>
    <dc:date>2022-06-13T12:56:53Z</dc:date>
    <item>
      <title>Fitting and simulating generalized pareto distribution</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817707#M40376</link>
      <description>&lt;P&gt;I'm trying to find the generalized pareto parameters for a univariate distribution, with the aim of simulating a dataset based on these parameters after. Proc univariate in the version of SAS I have doesn't allow for survey weights, so I have instead relied on the severity procedure.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;proc severity data=hnw_severity PLOTS=CDFPERDIST plots=pp plots=PDFPERDIST;&lt;BR /&gt;weight weighting;&lt;BR /&gt;loss Overall_Wealth;&lt;BR /&gt;dist Gpd;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I then get the following results:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Parameter Estimate StandardError&amp;nbsp; &amp;nbsp;t&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Pr &amp;gt; |t|&lt;/P&gt;&lt;P&gt;Theta&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 683294&amp;nbsp; &amp;nbsp; 6774&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 100.87 &amp;lt;.0001&lt;BR /&gt;Xi&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 0.36013&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;It has been somewhat difficult to track down the exact formula for simulating data. I've tried proc iml with the randgen function, but I don't believe this extends to GPD. Any guidance in using these parameters to simulate a new dataset would be greatly appreciated.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jun 2022 03:32:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817707#M40376</guid>
      <dc:creator>mkyron</dc:creator>
      <dc:date>2022-06-13T03:32:36Z</dc:date>
    </item>
    <item>
      <title>Re: Fitting and simulating generalized pareto distribution</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817723#M40378</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In this paper they simulate data with the Generalized Pareto Distribution (GPD) :&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;MWSUG 2018 - Paper AA-109&lt;BR /&gt;Application of heavy-tailed distribution using PROC IML, NLMIXED, and SEVERITY&lt;BR /&gt;Palash Sharma, University of Kansas Medical Center, Kansas City, KS&lt;BR /&gt;John Keighley, Ph.D. University of Kansas Medical Center, Kansas City, KS&lt;BR /&gt;&lt;A href="https://www.mwsug.org/proceedings/2018/AA/MWSUG-2018-AA-109.pdf" target="_blank"&gt;https://www.mwsug.org/proceedings/2018/AA/MWSUG-2018-AA-109.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Look also here :&lt;BR /&gt;MWSUG 2019 - Paper IN-116&lt;BR /&gt;Simulating Skewed Multivariate Distributions Using SAS®: Cases of Lomax, Mardia’s Pareto (Type I), Logistic, Burr and F Distributions&lt;BR /&gt;Zhixin Lun, Oakland University, Rochester, MI&lt;BR /&gt;Ravindra Khattree, Oakland University, Rochester, MI&lt;BR /&gt;&lt;A href="https://www.mwsug.org/proceedings/2019/IN/MWSUG-2019-IN-116.pdf" target="_blank"&gt;https://www.mwsug.org/proceedings/2019/IN/MWSUG-2019-IN-116.pdf&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13684"&gt;@Rick_SAS&lt;/a&gt;&amp;nbsp;: anything to add ?&lt;BR /&gt;I know that in your book "Simulating Data with SAS" you are also covering the&lt;BR /&gt;&amp;lt;&amp;lt; Generalized Pareto Distribution &amp;gt;&amp;gt;.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Good luck,&lt;/P&gt;
&lt;P&gt;Koen&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jun 2022 08:14:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817723#M40378</guid>
      <dc:creator>sbxkoenk</dc:creator>
      <dc:date>2022-06-13T08:14:31Z</dc:date>
    </item>
    <item>
      <title>Re: Fitting and simulating generalized pareto distribution</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817773#M40386</link>
      <description>&lt;A href="https://blogs.sas.com/content/iml/2018/11/05/fit-pareto-distribution-sas.html" target="_blank"&gt;https://blogs.sas.com/content/iml/2018/11/05/fit-pareto-distribution-sas.html&lt;/A&gt;</description>
      <pubDate>Mon, 13 Jun 2022 12:56:53 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817773#M40386</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2022-06-13T12:56:53Z</dc:date>
    </item>
    <item>
      <title>Re: Fitting and simulating generalized pareto distribution</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817776#M40387</link>
      <description>&lt;P&gt;Unfortunately, there are several distributions that all use the name "generalized Pareto."&amp;nbsp;I encourage the OP to make sure that the distribution in PROC SEVERITY is the form that they want. See&amp;nbsp;&lt;A href="https://blogs.sas.com/content/iml/2018/11/05/fit-pareto-distribution-sas.html" target="_blank"&gt;https://blogs.sas.com/content/iml/2018/11/05/fit-pareto-distribution-sas.html&lt;/A&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;As Koen says, p. 111 of &lt;EM&gt;Simulating Data with SAS&lt;/EM&gt; shows how to simulate from the generalized Pareto distribution that PROC SEVERITY uses. Here is the code for the OP's parameter estimates:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;%let N = 5000;
data GPD;
theta = 683294;
xi = 0.36013;
do i = 1 to &amp;amp;N;
   /* Generalized Pareto(scale=theta, shape=xi) */   
   U = rand("Uniform");
   X = theta/xi * (U**(-xi)-1);
   output;
end;
drop i U;
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;If you fit this random sample by using PROC SEVERITY (no weights), you should get parameter estimates that are close to the specified parameters.&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jun 2022 13:03:03 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817776#M40387</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2022-06-13T13:03:03Z</dc:date>
    </item>
    <item>
      <title>Re: Fitting and simulating generalized pareto distribution</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817781#M40389</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/13684"&gt;@Rick_SAS&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Unfortunately, there are several distributions that all use the name "generalized Pareto."&amp;nbsp;I encourage the OP to make sure that the distribution in PROC SEVERITY is the form that they want.&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Absolutely true !! Might be confusing.&lt;BR /&gt;Generalized Pareto , Generalized Gamma ... there are 3-parameter versions, 4-parameter versions (maybe 2-parameter versions?). There are also multiple flavours (parameterizations) of the formulae coming down to exactly the same thing of course.&lt;BR /&gt;So, I encourage OP as well (just as Rick) to make absolutely sure they are fitting and simulating what they want to fit and simulate.&lt;BR /&gt;&lt;BR /&gt;Last but not least :&lt;BR /&gt;If NLMIXED, SEVERITY, UNIVARIATE and so on can not estimate the parameters, I have always successfully done it with PROC OPTMODEL (SAS/OR &amp;amp; SAS Optimization). Take care : you should not make an error in the&amp;nbsp;maximum likelihood equation that you have to specify as an objective function!&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Cheers,&lt;/P&gt;
&lt;P&gt;Koen&lt;/P&gt;</description>
      <pubDate>Mon, 13 Jun 2022 13:20:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/817781#M40389</guid>
      <dc:creator>sbxkoenk</dc:creator>
      <dc:date>2022-06-13T13:20:07Z</dc:date>
    </item>
    <item>
      <title>Re: Fitting and simulating generalized pareto distribution</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/818091#M40397</link>
      <description>&lt;P&gt;Thanks all for the responses. This helped to get the solution I needed and also learn a lot more on the topic...much appreciated!&lt;/P&gt;</description>
      <pubDate>Tue, 14 Jun 2022 14:03:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Fitting-and-simulating-generalized-pareto-distribution/m-p/818091#M40397</guid>
      <dc:creator>mkyron</dc:creator>
      <dc:date>2022-06-14T14:03:26Z</dc:date>
    </item>
  </channel>
</rss>

