<?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 Distribution Fitting with Weights in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51005#M2257</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;But proc univariate has Weight statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ksharp&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 19 Aug 2011 08:29:41 GMT</pubDate>
    <dc:creator>Ksharp</dc:creator>
    <dc:date>2011-08-19T08:29:41Z</dc:date>
    <item>
      <title>Distribution Fitting with Weights</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51004#M2256</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am trying fit a lognormal distribution to data that has weights.&amp;nbsp; For instance, a particular observation may represent 2000 households while another one may represent 500 households.&amp;nbsp; The data set contains a variable, "weight," that represents each observation's proportional weighting.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Proc Univariate does not allow the "Weight" option to be used when using any of the statements that do distribution fitting.&amp;nbsp; The parameter estimates are desired as well as the test statistics and accompannying p-values.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;What is the best way to fit distributions to weighted data?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Scott&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Aug 2011 23:39:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51004#M2256</guid>
      <dc:creator>SColby</dc:creator>
      <dc:date>2011-08-18T23:39:07Z</dc:date>
    </item>
    <item>
      <title>Distribution Fitting with Weights</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51005#M2257</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;But proc univariate has Weight statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Ksharp&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Aug 2011 08:29:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51005#M2257</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2011-08-19T08:29:41Z</dc:date>
    </item>
    <item>
      <title>Re: Distribution Fitting with Weights</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51006#M2258</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Do you have access to PROC CAPABILITY? The following code was generated by EG4.3.&amp;nbsp; I used anml_no as a weight, and it generated a pretty nice looking lognormal dataset this way.&amp;nbsp; The output had the goodness-of-fit tests for a lognormal distribution.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN lang="EN"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;PROC CAPABILITY DATA = WORK.SORTTempTableSorted&lt;/P&gt;&lt;P&gt;CIBASIC(TYPE=TWOSIDED ALPHA=0.05)&lt;/P&gt;&lt;P&gt;MU0=0&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;WEIGHT anml_no;&lt;/P&gt;&lt;P&gt;VAR IgG;&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;HISTOGRAM IgG / LOGNORMAL ( W=1 L=1 COLOR=LIME ZETA=EST THETA=EST &lt;/P&gt;&lt;P&gt;SIGMA=EST)&lt;/P&gt;&lt;P&gt;CAXIS=PURPLE&lt;/P&gt;&lt;P&gt;CTEXT=BLACK&lt;/P&gt;&lt;P&gt;CFRAME=WHITE&lt;/P&gt;&lt;P&gt;CBARLINE=BLACK&lt;/P&gt;&lt;P&gt;CFILL=GRAY&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;/* -------------------------------------------------------------------&lt;/P&gt;&lt;P&gt;End of task code.&lt;/P&gt;&lt;P&gt;------------------------------------------------------------------- */&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;RUN; QUIT;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN lang="EN"&gt; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN lang="EN"&gt;Good luck.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN lang="EN"&gt; &lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN lang="EN"&gt;Steve Denham&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Message was edited by: Steve Denham&#xD;
&#xD;
Unfortunately, after digging a little deeper, I don't think the goodness-of-fit tests are weighted.&amp;nbsp; I get exactly the same values with and without the weight statement.&amp;nbsp; Only the basic stats and tests for location appear to actually use the weights.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Aug 2011 10:38:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51006#M2258</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2011-08-19T10:38:39Z</dc:date>
    </item>
    <item>
      <title>Re: Distribution Fitting with Weights</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51007#M2259</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The Weight statement cannot be used in conjunction with the histogram statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Scott&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Aug 2011 17:16:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51007#M2259</guid>
      <dc:creator>SColby</dc:creator>
      <dc:date>2011-08-19T17:16:21Z</dc:date>
    </item>
    <item>
      <title>Re: Distribution Fitting with Weights</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51008#M2260</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I discovered the same thing running Proc Capability on my data: the parameter estimates are identical whether or not I include a Weight statement.&amp;nbsp; This is the case for lognormal, Weibull and gamma fits.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks for the suggestion though.&amp;nbsp; It surprises me that such a simple and commonly needed operation isn't built directly into these procesures.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Not sure where to go from here.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Scott&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Aug 2011 22:38:50 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51008#M2260</guid>
      <dc:creator>SColby</dc:creator>
      <dc:date>2011-08-19T22:38:50Z</dc:date>
    </item>
    <item>
      <title>Re: Distribution Fitting with Weights</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51009#M2261</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I gave a presentation on this topic a few years ago at the Joint Statistical Meetings, and I disagree that this is a simple operation. The two major difficulties are (1) weighted histograms are not simple to define and understand, and (2) a weighted fit is not well-defined.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The WEIGHT statement in UNIVARIATE has the following meaning (from the doc):&lt;/P&gt;&lt;P&gt;The UNIVARIATE procedure uses the values &lt;IMG class="math gen" src="http://support.sas.com/documentation/cdl/en/procstat/63963/HTML/default/images/procstat_univariate0147.png" style="width: 13px; height: 9px; vertical-align: -2px;" /&gt; of the WEIGHT variable to modify the computation of a number of summary statistics by assuming that the variance of the &lt;IMG class="math gen" src="http://support.sas.com/documentation/cdl/en/procstat/63963/HTML/default/images/procstat_univariate0025.png" style="width: 4px; height: 10px;" /&gt;th value &lt;IMG class="math gen" src="http://support.sas.com/documentation/cdl/en/procstat/63963/HTML/default/images/procstat_univariate0148.png" style="width: 11px; height: 9px; vertical-align: -2px;" /&gt; of the analysis variable is equal to &lt;IMG class="math gen" src="http://support.sas.com/documentation/cdl/en/procstat/63963/HTML/default/images/procstat_univariate0149.png" style="width: 36px; height: 17px; vertical-align: -4px;" /&gt;, where &lt;IMG class="math gen" src="http://support.sas.com/documentation/cdl/en/procstat/63963/HTML/default/images/procstat_univariate0039.png" style="width: 9px; height: 8px;" /&gt; is an unknown parameter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The implications of this is that &lt;EM&gt;each &lt;/EM&gt;observation is from a &lt;EM&gt;different &lt;/EM&gt;distribution! You can't put a single "fitted curve" on top of a histogram because no such curve exists. Even if you solve for the common variance, &lt;IMG class="math gen" src="http://support.sas.com/documentation/cdl/en/procstat/63963/HTML/default/images/procstat_univariate0039.png" style="width: 9px; height: 8px;" /&gt;, that doesn't do you much good because you can't use it to overlay a density estimate or to do a GOF test.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem of constructing a weighted statistical graphic is still an area of research. I'll give you the same challenge I gave the statisticians at JSM: find a paper (in a reputable journal) in which weighted histograms are defined and weighted fits are described. Send that paper to me at SAS and I'll pass it on to the UNIVARIATE developer.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As to where should you go from here, if the weights are inverse probablities, then perhaps you can define FREQ = 1/WEIGHT and use a FREQ statement. Histograms, fits, GOF tests, etc, are well-defined for count data.&amp;nbsp; It sounds like this might be survey data, and if so you should use the SURVEY* procs (SURVEYMEANS, SURVEYFREQ, etc) to analyze survey data. These procs make the correct adjustments when computing variance of variables.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 21 Aug 2011 10:24:45 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Distribution-Fitting-with-Weights/m-p/51009#M2261</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2011-08-21T10:24:45Z</dc:date>
    </item>
  </channel>
</rss>

