<?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 How do I present in a table the mean and standard deviation of 34 variables X1-X34 ordered from the in SAS Studio</title>
    <link>https://communities.sas.com/t5/SAS-Studio/How-do-I-present-in-a-table-the-mean-and-standard-deviation-of/m-p/772229#M10230</link>
    <description>&lt;P&gt;How do I present in a table the mean and standard deviation of 34 variables X1-X34 ordered&lt;BR /&gt;from the highest to the lowest value of the mean?&lt;/P&gt;</description>
    <pubDate>Tue, 05 Oct 2021 17:06:31 GMT</pubDate>
    <dc:creator>NPConcorida</dc:creator>
    <dc:date>2021-10-05T17:06:31Z</dc:date>
    <item>
      <title>How do I present in a table the mean and standard deviation of 34 variables X1-X34 ordered from the</title>
      <link>https://communities.sas.com/t5/SAS-Studio/How-do-I-present-in-a-table-the-mean-and-standard-deviation-of/m-p/772229#M10230</link>
      <description>&lt;P&gt;How do I present in a table the mean and standard deviation of 34 variables X1-X34 ordered&lt;BR /&gt;from the highest to the lowest value of the mean?&lt;/P&gt;</description>
      <pubDate>Tue, 05 Oct 2021 17:06:31 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/How-do-I-present-in-a-table-the-mean-and-standard-deviation-of/m-p/772229#M10230</guid>
      <dc:creator>NPConcorida</dc:creator>
      <dc:date>2021-10-05T17:06:31Z</dc:date>
    </item>
    <item>
      <title>Re: How do I present in a table the mean and standard deviation of 34 variables X1-X34 ordered from</title>
      <link>https://communities.sas.com/t5/SAS-Studio/How-do-I-present-in-a-table-the-mean-and-standard-deviation-of/m-p/772249#M10231</link>
      <description>&lt;P&gt;&lt;A href="https://gist.github.com/statgeek/d4c36ea88523d49e135a7aa494c29846" target="_blank" rel="noopener"&gt;https://gist.github.com/statgeek/d4c36ea88523d49e135a7aa494c29846&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;In this example, I sort by N, but hopefully you can see how to extend it to MEAN instead.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;*generate fake data;
data have;
    array a(17);

    do i=1 to 100;

        do j=1 to 17;
            a(j)=rand('bernoulli', 0.27);

            if rand('bernoulli', 0.1)=1 then
                call missing(a(j));
        end;
        output;
    end;
run;

*Summary statistics;
proc means data=have stackods n sum mean maxdec=1;
    var a1-a17;
    ods output summary=want;
run;

*sort by N, descending count, and print;
proc sort data=want;
    by descending n;
run;

proc print data=want label noobs;
    label variable='Defect Categories';
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/401676"&gt;@NPConcorida&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;How do I present in a table the mean and standard deviation of 34 variables X1-X34 ordered&lt;BR /&gt;from the highest to the lowest value of the mean?&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 05 Oct 2021 19:08:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Studio/How-do-I-present-in-a-table-the-mean-and-standard-deviation-of/m-p/772249#M10231</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2021-10-05T19:08:36Z</dc:date>
    </item>
  </channel>
</rss>

