<?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: After Call Tabulate in Proc IML, Am I Able to Save the Output Table as a New Dataset? in SAS/IML Software and Matrix Computations</title>
    <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812389#M5811</link>
    <description>&lt;P&gt;KSharp has already answered your question. See the end of his program.&lt;/P&gt;</description>
    <pubDate>Tue, 10 May 2022 12:53:37 GMT</pubDate>
    <dc:creator>Rick_SAS</dc:creator>
    <dc:date>2022-05-10T12:53:37Z</dc:date>
    <item>
      <title>After Call Tabulate in Proc IML, Am I Able to Save the Output Table as a New Dataset?</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812265#M5806</link>
      <description>&lt;P&gt;Hi all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;First name here and in need of some assistance. I have a dataset that looks something like the following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Q4 Q5_1 Q5_2 Q5_3&lt;/P&gt;&lt;P&gt;&amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;/P&gt;&lt;P&gt;&amp;nbsp;2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;/P&gt;&lt;P&gt;&amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;/P&gt;&lt;P&gt;&amp;nbsp;5&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The values within the&amp;nbsp;Q5_1, Q5_2, and Q5_3 columns are of the same type and I am looking to determine the frequency of the responses across the entire matrix (Q4 is a participant type).&amp;nbsp;I have been able to develop an IML code to produce an output table for just one of the participant types as below.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;PROC IML;
   Use Data.Have;
   Read all var{Q5_1 Q5_2 Q5_3} where (Q4 = 1) into x;
Close;
Call tabulate(level,freq,x,);
Print (level`)[l='level'] (freq`)[l='freq'];
Quit;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;This generates an output table that looks like the following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV&gt;&lt;DIV align="center"&gt;level freq &lt;TABLE cellspacing="0" cellpadding="5"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;TD&gt;151&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;1399&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;TD&gt;206&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I am wondering is if it is possible to save this output table as a new dataset after using the Call Tabulate function?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Appreciate any and all suggestions and thank you!&lt;/P&gt;</description>
      <pubDate>Mon, 09 May 2022 21:43:09 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812265#M5806</guid>
      <dc:creator>agille05</dc:creator>
      <dc:date>2022-05-09T21:43:09Z</dc:date>
    </item>
    <item>
      <title>Re: After Call Tabulate in Proc IML, Am I Able to Save the Output Table as a New Dataset?</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812291#M5807</link>
      <description>&lt;P&gt;Yes. you could. but you have to post it at IML forum.&lt;/P&gt;
&lt;P&gt;&lt;A href="https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/bd-p/sas_iml" target="_blank"&gt;https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/bd-p/sas_iml&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;data have;
input Q4 Q5_1 Q5_2 Q5_3;
cards;
 1        1       1       2
 2        1       1       1
 1        1       0       2
 5        2       1       2
;

PROC IML;
   Use Have;
   Read all var{Q5_1 Q5_2 Q5_3} where (Q4 = 1) into x;
Close;
Call tabulate(level,freq,x,);

create want var{level freq};
append ;
close;
Quit;&lt;/PRE&gt;</description>
      <pubDate>Tue, 10 May 2022 03:47:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812291#M5807</guid>
      <dc:creator>Ksharp</dc:creator>
      <dc:date>2022-05-10T03:47:51Z</dc:date>
    </item>
    <item>
      <title>Re: After Call Tabulate in Proc IML, Am I Able to Save the Output Table as a New Dataset?</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812381#M5808</link>
      <description>&lt;P&gt;Will do! Thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2022 12:41:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812381#M5808</guid>
      <dc:creator>agille05</dc:creator>
      <dc:date>2022-05-10T12:41:13Z</dc:date>
    </item>
    <item>
      <title>After Call Tabulate in Proc IML, Am I Able to Save the Output Table as a New Dataset?</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812387#M5810</link>
      <description>&lt;P&gt;Hi all,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;First name here and in need of some assistance. I have a dataset that looks something like the following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Q4 Q5_1 Q5_2 Q5_3&lt;/P&gt;&lt;P&gt;&amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;/P&gt;&lt;P&gt;&amp;nbsp;2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&lt;/P&gt;&lt;P&gt;&amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;0&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;/P&gt;&lt;P&gt;&amp;nbsp;5&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 2&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;1&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;2&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The values within the&amp;nbsp;Q5_1, Q5_2, and Q5_3 columns are of the same type and I am looking to determine the frequency of the responses across the entire matrix (Q4 is a participant type).&amp;nbsp;I have been able to develop an IML code to produce an output table for just one of the participant types as below.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;PROC IML;
   Use Data.Have;
   Read all var{Q5_1 Q5_2 Q5_3} where (Q4 = 1) into x;
Close;
Call tabulate(level,freq,x,);

Print (level`)[l='level'] (freq`)[l='freq'];

Quit;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;This generates an output table that looks like the following:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;DIV class=""&gt;&lt;DIV&gt;&lt;DIV align="center"&gt;level freq &lt;TABLE cellspacing="0" cellpadding="5"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD&gt;0&lt;/TD&gt;&lt;TD&gt;151&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;1&lt;/TD&gt;&lt;TD&gt;1399&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD&gt;2&lt;/TD&gt;&lt;TD&gt;206&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What I am wondering is if it is possible to save this output table as a new dataset after using the Call Tabulate function?&lt;/P&gt;&lt;P&gt;Appreciate any and all suggestions! Thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2022 12:48:08 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812387#M5810</guid>
      <dc:creator>agille05</dc:creator>
      <dc:date>2022-05-10T12:48:08Z</dc:date>
    </item>
    <item>
      <title>Re: After Call Tabulate in Proc IML, Am I Able to Save the Output Table as a New Dataset?</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812389#M5811</link>
      <description>&lt;P&gt;KSharp has already answered your question. See the end of his program.&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2022 12:53:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812389#M5811</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2022-05-10T12:53:37Z</dc:date>
    </item>
    <item>
      <title>Re: After Call Tabulate in Proc IML, Am I Able to Save the Output Table as a New Dataset?</title>
      <link>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812391#M5812</link>
      <description>&lt;P&gt;Oh I see it now! Thank you &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 10 May 2022 13:10:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-IML-Software-and-Matrix/After-Call-Tabulate-in-Proc-IML-Am-I-Able-to-Save-the-Output/m-p/812391#M5812</guid>
      <dc:creator>agille05</dc:creator>
      <dc:date>2022-05-10T13:10:14Z</dc:date>
    </item>
  </channel>
</rss>

