<?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 Variance of a weighted sum in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112946#M31284</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi folks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody shed some insight on the procedure to use for calculating the variance of a weighted sum?&amp;nbsp; Basically what I'm looking for is SAS 9.3 code to calculate var(z) in the following equation:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;var(z) = a^2[var(x)] + b^2[var(y)]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;a&amp;amp;b are the weights, x&amp;amp;y are the variables for which variance is to be calculated.&amp;nbsp; More information can be provided if necessary.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance for considering.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 13 May 2012 07:10:21 GMT</pubDate>
    <dc:creator>sas_new_user</dc:creator>
    <dc:date>2012-05-13T07:10:21Z</dc:date>
    <item>
      <title>Variance of a weighted sum</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112946#M31284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi folks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody shed some insight on the procedure to use for calculating the variance of a weighted sum?&amp;nbsp; Basically what I'm looking for is SAS 9.3 code to calculate var(z) in the following equation:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;var(z) = a^2[var(x)] + b^2[var(y)]&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;a&amp;amp;b are the weights, x&amp;amp;y are the variables for which variance is to be calculated.&amp;nbsp; More information can be provided if necessary.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance for considering.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 13 May 2012 07:10:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112946#M31284</guid>
      <dc:creator>sas_new_user</dc:creator>
      <dc:date>2012-05-13T07:10:21Z</dc:date>
    </item>
    <item>
      <title>Re: Variance of a weighted sum</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112947#M31285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;proc means , proc summary ,proc univariate ........... can do it.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;proc means data=sashelp.class nway noprint;
class sex;
var height;
weight age;
output out=want var=height_weight_var ;
run;

&lt;/PRE&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;Ksharp&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 May 2012 03:14:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112947#M31285</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2012-05-14T03:14:26Z</dc:date>
    </item>
    <item>
      <title>Re: Variance of a weighted sum</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112948#M31286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;To use two different weights you will need to make a pass through means for each weight variable.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Then combine the two resulting data sets to calculate your var( Z).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 14 May 2012 16:13:56 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112948#M31286</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2012-05-14T16:13:56Z</dc:date>
    </item>
    <item>
      <title>Re: Variance of a weighted sum</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112949#M31287</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Ou. Sorry ! I misunderstood what op mean. I even don't notice there are two variables being the weight. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 15 May 2012 02:39:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Variance-of-a-weighted-sum/m-p/112949#M31287</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2012-05-15T02:39:25Z</dc:date>
    </item>
  </channel>
</rss>

