<?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: Macro to contain list of variable names in SAS Enterprise Guide</title>
    <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133956#M10845</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you very much, seems to work.&lt;/P&gt;&lt;P&gt;I'll be back if i have any other requests :smileysilly:&lt;/P&gt;&lt;P&gt;Gd day to you &lt;img id="smileywink" class="emoticon emoticon-smileywink" src="https://communities.sas.com/i/smilies/16x16_smiley-wink.png" alt="Smiley Wink" title="Smiley Wink" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 14 May 2013 15:55:47 GMT</pubDate>
    <dc:creator>M_A_C</dc:creator>
    <dc:date>2013-05-14T15:55:47Z</dc:date>
    <item>
      <title>Macro to contain list of variable names</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133952#M10841</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I am a noob concerning SAS programming. I came across a clustering method that i am applying to some sample data. I need a macro to contain a list of variable names and each time i call it it brings them, like a vector of some sort. Anyone keen on macro programming?&lt;/P&gt;&lt;P&gt;Here is the pdf i found with the clustering technique(&lt;A href="http://support.sas.com/resources/papers/proceedings13/068-2013.pdf" title="http://support.sas.com/resources/papers/proceedings13/068-2013.pdf"&gt;http://support.sas.com/resources/papers/proceedings13/068-2013.pdf&lt;/A&gt;), in page 4 it says :&lt;/P&gt;&lt;P&gt;"The macros all_name and sm_name refer to the list of the variables of product frequencies and &lt;/P&gt;&lt;P&gt;the corresponding list of variables to be standardized (preceded by SM_), respectively&lt;SPAN style="font-size: 10pt; line-height: 1.5em;"&gt;"&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help is welcome.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you. Gd day to ye !&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 13:39:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133952#M10841</guid>
      <dc:creator>M_A_C</dc:creator>
      <dc:date>2013-05-13T13:39:05Z</dc:date>
    </item>
    <item>
      <title>Re: Macro to contain list of variable names</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133953#M10842</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi.&lt;/P&gt;&lt;P&gt;Would something like this work?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(I am using sashelp.class)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;*select the variable names once in the list &lt;EM&gt;all_name&lt;/EM&gt; then in &lt;EM&gt;sm_name&amp;nbsp; &lt;/EM&gt;- to be later used for standardization&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;proc sql;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; select name, &lt;STRONG&gt;compress("sm_" ||name)&lt;/STRONG&gt; into: all_name separated by " ",&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; : sm_name separated by " "&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; from dictionary.columns&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; where libname = "SASHELP" &amp;amp; memname = "CLASS" &amp;amp; name not in ("Name", "Sex");&lt;/P&gt;&lt;P&gt;quit;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data temp;&lt;/P&gt;&lt;P&gt;set sashelp.class ;&lt;/P&gt;&lt;P&gt;keep &amp;amp;all_name. &amp;amp;sm_name. name ;&lt;/P&gt;&lt;P&gt;array&amp;nbsp; avar {*} &amp;amp;all_name. ;&lt;/P&gt;&lt;P&gt;array&amp;nbsp; svar {*} &amp;amp;sm_name. ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;do i = 1 to dim(avar);&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; svar(i) = avar(i);&lt;/P&gt;&lt;P&gt;end;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Good luck!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anca.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 13 May 2013 15:31:46 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133953#M10842</guid>
      <dc:creator>AncaTilea</dc:creator>
      <dc:date>2013-05-13T15:31:46Z</dc:date>
    </item>
    <item>
      <title>Re: Macro to contain list of variable names</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133954#M10843</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey anca,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Anca, romanian girl name i'm guessing :smileygrin:, nice !&lt;/P&gt;&lt;P&gt;Thank you for your feedback.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I tried the given code with some modifications. to add 3 more extra tables. I need to use them to keep the univariate analysis results. It gave me the name as requested.&lt;/P&gt;&lt;P&gt;I will carry and try on applying it to the rest needed to see if it fits in the whole process right.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 08:04:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133954#M10843</guid>
      <dc:creator>M_A_C</dc:creator>
      <dc:date>2013-05-14T08:04:11Z</dc:date>
    </item>
    <item>
      <title>Re: Macro to contain list of variable names</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133955#M10844</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;img id="smileywink" class="emoticon emoticon-smileywink" src="https://communities.sas.com/i/smilies/16x16_smiley-wink.png" alt="Smiley Wink" title="Smiley Wink" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 12:04:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133955#M10844</guid>
      <dc:creator>AncaTilea</dc:creator>
      <dc:date>2013-05-14T12:04:55Z</dc:date>
    </item>
    <item>
      <title>Re: Macro to contain list of variable names</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133956#M10845</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you very much, seems to work.&lt;/P&gt;&lt;P&gt;I'll be back if i have any other requests :smileysilly:&lt;/P&gt;&lt;P&gt;Gd day to you &lt;img id="smileywink" class="emoticon emoticon-smileywink" src="https://communities.sas.com/i/smilies/16x16_smiley-wink.png" alt="Smiley Wink" title="Smiley Wink" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 15:55:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133956#M10845</guid>
      <dc:creator>M_A_C</dc:creator>
      <dc:date>2013-05-14T15:55:47Z</dc:date>
    </item>
    <item>
      <title>Re: Macro to contain list of variable names</title>
      <link>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133957#M10846</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Glad it worked.&lt;/P&gt;&lt;P&gt;&lt;img id="smileyhappy" class="emoticon emoticon-smileyhappy" src="https://communities.sas.com/i/smilies/16x16_smiley-happy.png" alt="Smiley Happy" title="Smiley Happy" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 May 2013 16:03:07 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Enterprise-Guide/Macro-to-contain-list-of-variable-names/m-p/133957#M10846</guid>
      <dc:creator>AncaTilea</dc:creator>
      <dc:date>2013-05-14T16:03:07Z</dc:date>
    </item>
  </channel>
</rss>

