<?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: Create a loop to handle a dataset with many variables (columns) in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762455#M241432</link>
    <description>&lt;P&gt;I don't see how breaking the dataset up is going to make calculating new variables any easier.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Whether there is any way to simplify the coding depends a lot on how complex the calculation is. And how consistent the grouping of the variables is.&amp;nbsp; Are the there 25 groups of 4 variables?&amp;nbsp; Or 20 groups of 5 variables? Or between 20 and 25 groups of between 4 and 5 variables?&lt;/P&gt;</description>
    <pubDate>Thu, 19 Aug 2021 04:30:52 GMT</pubDate>
    <dc:creator>Tom</dc:creator>
    <dc:date>2021-08-19T04:30:52Z</dc:date>
    <item>
      <title>Create a loop to handle a dataset with many variables (columns)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762451#M241428</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;Now I'm handling&amp;nbsp;a dataset with nearly 100 variables (already name var1 to varxx). The situation is that these variables could be divided in to blocks (4 to 5 variables within each block) and I want to create 2 more variables from each block. The logic to create new variables is the same with all blocks.&lt;/P&gt;&lt;P&gt;My way of thinking is to split the original dataset to sub-datasets, each&amp;nbsp;sub-dataset has one block of variables, create and split new variables, then join new variables together. My problem now is to create a loop to handle those datasets (bcs the logic to handle is the same) but the names of variables are different among datasets.&lt;/P&gt;&lt;P&gt;How could I deal with this situation ? Or is there any better way to deal with it in the first place&lt;/P&gt;&lt;P&gt;Thanks in advance&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 19 Aug 2021 04:08:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762451#M241428</guid>
      <dc:creator>James_Yu</dc:creator>
      <dc:date>2021-08-19T04:08:05Z</dc:date>
    </item>
    <item>
      <title>Re: Create a loop to handle a dataset with many variables (columns)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762455#M241432</link>
      <description>&lt;P&gt;I don't see how breaking the dataset up is going to make calculating new variables any easier.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Whether there is any way to simplify the coding depends a lot on how complex the calculation is. And how consistent the grouping of the variables is.&amp;nbsp; Are the there 25 groups of 4 variables?&amp;nbsp; Or 20 groups of 5 variables? Or between 20 and 25 groups of between 4 and 5 variables?&lt;/P&gt;</description>
      <pubDate>Thu, 19 Aug 2021 04:30:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762455#M241432</guid>
      <dc:creator>Tom</dc:creator>
      <dc:date>2021-08-19T04:30:52Z</dc:date>
    </item>
    <item>
      <title>Re: Create a loop to handle a dataset with many variables (columns)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762456#M241433</link>
      <description>&lt;P&gt;In my case, there are 14 groups of 5 and 6 groups of 4. All 6 groups of 4 will be proceeded in the same way. In 14 groups of 5, 10 groups will be in one part and the remaining will be in the other part. There will be 3 ways to proceed the data to achieve 2 new variables with each group&lt;/P&gt;</description>
      <pubDate>Thu, 19 Aug 2021 04:41:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762456#M241433</guid>
      <dc:creator>James_Yu</dc:creator>
      <dc:date>2021-08-19T04:41:15Z</dc:date>
    </item>
    <item>
      <title>Re: Create a loop to handle a dataset with many variables (columns)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762470#M241436</link>
      <description>In general, this sounds like a need for one DATA step with several two dimensional arrays.  If you want more specific help you will need to provide complete coding for one set of variables.</description>
      <pubDate>Thu, 19 Aug 2021 06:53:43 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762470#M241436</guid>
      <dc:creator>Astounding</dc:creator>
      <dc:date>2021-08-19T06:53:43Z</dc:date>
    </item>
    <item>
      <title>Re: Create a loop to handle a dataset with many variables (columns)</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762476#M241441</link>
      <description>&lt;P&gt;You need to be more specific in your explanations.&lt;/P&gt;</description>
      <pubDate>Thu, 19 Aug 2021 07:45:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Create-a-loop-to-handle-a-dataset-with-many-variables-columns/m-p/762476#M241441</guid>
      <dc:creator>ChrisNZ</dc:creator>
      <dc:date>2021-08-19T07:45:14Z</dc:date>
    </item>
  </channel>
</rss>

