<?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: SAS Macro Do Loop in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95632#M20131</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for the reply. The flag worked perfectly. I was trying to program a loop for a long time and ust out of curiosity how would a loop work? I could not figure it out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Todd&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 03 Feb 2013 15:43:05 GMT</pubDate>
    <dc:creator>toddtodd</dc:creator>
    <dc:date>2013-02-03T15:43:05Z</dc:date>
    <item>
      <title>SAS Macro Do Loop</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95629#M20128</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a cross-sectional time series data set. I have a cusip and time id. I would like to write a loop that performs a calculation every time period until the stopping command for every cusip. For example the data set looks like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Cusip&amp;nbsp;&amp;nbsp; Time&amp;nbsp;&amp;nbsp; Yield&amp;nbsp; Coupon&amp;nbsp;&amp;nbsp;&amp;nbsp; Principal&lt;/P&gt;&lt;P&gt;x9900&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.02&amp;nbsp;&amp;nbsp; 0.01&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10,000&lt;/P&gt;&lt;P&gt;x9900&amp;nbsp;&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.02&amp;nbsp;&amp;nbsp; 0.015&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10,000&lt;/P&gt;&lt;P&gt;x9900&amp;nbsp;&amp;nbsp; 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.02&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.022&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10,000&lt;/P&gt;&lt;P&gt;5H33&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.025&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5,000&lt;/P&gt;&lt;P&gt;5h33&amp;nbsp;&amp;nbsp;&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.033&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5,000&lt;/P&gt;&lt;P&gt;5h33&amp;nbsp;&amp;nbsp;&amp;nbsp; 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.029&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5,000&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I would like to write a loop that multiplies Principal times coupon for every time period (by cusipu) but stops when the coupon is greater than the yield. The reason I would like a loop is because I want the calculation of principal times coupon to stop permanently for a cusip when the coupon is greater than the yield. For example, for the cusip 5h33 the coupon is greater than the yield at time 2. So the calculation should stop at time 2. However, at time 3 the coupon is less than the yield. Without a loop the multiplication continues, however, I want it to stop.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any help please would be great.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Todd Feldman&lt;/P&gt;&lt;P&gt;Assistant Professor&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 02 Feb 2013 22:57:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95629#M20128</guid>
      <dc:creator>toddtodd</dc:creator>
      <dc:date>2013-02-02T22:57:58Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Macro Do Loop</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95630#M20129</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 don't understand what you need a Macro loop for. What is your desired output? The way I understand your explanation, you would only multiply on two of these observations:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;Cusip&amp;nbsp;&amp;nbsp;&amp;nbsp; Time&amp;nbsp;&amp;nbsp;&amp;nbsp; Yield&amp;nbsp;&amp;nbsp;&amp;nbsp; Coupon&amp;nbsp;&amp;nbsp;&amp;nbsp; Principal&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; do_this&amp;nbsp; Result?&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&lt;SPAN class="baec5a81-e4d6-4674-97f3-e9220f0136c1" style="white-space: nowrap;"&gt;x9900&lt;A href="#" style="margin: 0px; border: currentColor; left: 0px; top: 0px; width: 16px; height: 16px; right: 0px; bottom: 0px; overflow: hidden; vertical-align: middle; float: none; display: inline; white-space: nowrap; position: static !important;" title="Call: x9900"&gt;#&lt;/A&gt;&lt;/SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.02&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.010&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10,000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; no mult&amp;nbsp;&amp;nbsp;&amp;nbsp; ??&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&lt;SPAN class="baec5a81-e4d6-4674-97f3-e9220f0136c1" style="white-space: nowrap;"&gt;x9900&lt;A href="#" style="margin: 0px; border: currentColor; left: 0px; top: 0px; width: 16px; height: 16px; right: 0px; bottom: 0px; overflow: hidden; vertical-align: middle; float: none; display: inline; white-space: nowrap; position: static !important;" title="Call: x9900"&gt;#&lt;/A&gt;&lt;/SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.02&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.015&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10,000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; no mult&amp;nbsp;&amp;nbsp;&amp;nbsp; ??&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&lt;SPAN class="baec5a81-e4d6-4674-97f3-e9220f0136c1" style="white-space: nowrap;"&gt;x9900&lt;A href="#" style="margin: 0px; border: currentColor; left: 0px; top: 0px; width: 16px; height: 16px; right: 0px; bottom: 0px; overflow: hidden; vertical-align: middle; float: none; display: inline; white-space: nowrap; position: static !important;" title="Call: x9900"&gt;#&lt;/A&gt;&lt;/SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.02&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.022&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 10,000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #008000;"&gt;multiply&lt;/SPAN&gt;&amp;nbsp;&amp;nbsp; ??&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;5H33&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.025&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5,000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; no mult&amp;nbsp;&amp;nbsp;&amp;nbsp; ??&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;5h33&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.033&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5,000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #008000;"&gt;multiply&lt;/SPAN&gt;&amp;nbsp;&amp;nbsp; ??&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG style="font-family: courier new,courier;"&gt;5h33&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.03&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 0.029&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 5,000&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; no mult&amp;nbsp;&amp;nbsp;&amp;nbsp; ??&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But if you have 6 rows in your data, what do you envision on each row? A calculated field that is cumulative based on multiplying or not multiplying??? And for each CUSIP, the calculated amount starts over at 0? Can you explain what you would want to see at the end of this process?? 6 rows in and 6 rows out or 6 rows in and 2 rows out (one for each CUSIP)?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;cynthia&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Feb 2013 00:52:58 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95630#M20129</guid>
      <dc:creator>Cynthia_sas</dc:creator>
      <dc:date>2013-02-03T00:52:58Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Macro Do Loop</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95631#M20130</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cynthia is correct you don't need macros. What you do need is to set a flag when the coupon is greater than yield and then retain it until the next by group. At the start of the next by group you set the flag back to the initial value.&lt;/P&gt;&lt;P&gt;Key ideas: By Group and Retain.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Untested, but hopefully gives you the idea.&lt;/P&gt;&lt;P&gt;If the coupon is greater than the yield then the return is 0, else it is the principal * yield. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data want;&lt;/P&gt;&lt;P&gt;set have;&lt;/P&gt;&lt;P&gt;by cusip;&lt;/P&gt;&lt;P&gt;retain flag;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if first.cusip then&amp;nbsp; flag=0;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if coupon &amp;gt; yield then flag=1;&lt;/P&gt;&lt;P&gt;if flag ne 1 then return=principal*coupon;&lt;/P&gt;&lt;P&gt;else return=0;&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Feb 2013 03:12:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95631#M20130</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2013-02-03T03:12:33Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Macro Do Loop</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95632#M20131</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for the reply. The flag worked perfectly. I was trying to program a loop for a long time and ust out of curiosity how would a loop work? I could not figure it out.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Todd&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Feb 2013 15:43:05 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95632#M20131</guid>
      <dc:creator>toddtodd</dc:creator>
      <dc:date>2013-02-03T15:43:05Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Macro Do Loop</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95633#M20132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In order to show you how you could do what you want with a loop, you first have to provide an example dataset WITH desired results.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Do you realize that the datastep, itself, functions via a loop?&amp;nbsp; You can introduce additional loops, when necessary, but that will get confusing unless we know what you are trying to use it for.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It would also help if you posted the code that you wrote in your own attempts to introduce a loop in the process.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 03 Feb 2013 16:05:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95633#M20132</guid>
      <dc:creator>art297</dc:creator>
      <dc:date>2013-02-03T16:05:04Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Macro Do Loop</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95634#M20133</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Here is an example of the data set. The result is cash_interest. Not sure if my attempts will help. I kept getting weird results. I appreciate the comments.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;TABLE border="0" cellpadding="0" cellspacing="0" width="599"&gt;&lt;TBODY&gt;&lt;TR&gt;&lt;TD class="xl64" height="20" width="105"&gt;Cusip&lt;/TD&gt;&lt;TD class="xl65" style="border-left: none;" width="75"&gt;Date&lt;/TD&gt;&lt;TD class="xl65" style="border-left: none;" width="48"&gt;month&lt;/TD&gt;&lt;TD class="xl65" style="border-left: none;" width="111"&gt;Ending_Principal&lt;/TD&gt;&lt;TD class="xl65" style="border-left: none;" width="111"&gt;yield&lt;/TD&gt;&lt;TD class="xl65" style="border-left: none;" width="56"&gt;coupon&lt;/TD&gt;&lt;TD class="xl67" style="border-left: none;" width="93"&gt;Cash_Interest&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;12/31/2012&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;0&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;45100000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;1/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;1&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;45100000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00245&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$110,495&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;2/28/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;2&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;45100000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00245&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$110,495&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;3/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;3&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;45100000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00509&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$229,559&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;4/30/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;4&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;45100000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00463&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$208,813&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;5/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;5&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;45100000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00528&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$238,128&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;6/30/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;6&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;44000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00594&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;05922KHH5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;7/30/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;7&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;44000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.053&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.06&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;12/31/2012&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;0&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;1/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;1&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.0037&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$277,500&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;2/28/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;2&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00522&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$391,500&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;3/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;3&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00742&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$556,500&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;4/30/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;4&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.00911&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$683,250&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;5/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;5&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.01277&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$957,750&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;6/30/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;6&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.01559&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;7/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;7&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.01621&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$0&lt;/TD&gt;&lt;/TR&gt;&lt;TR&gt;&lt;TD class="xl66" height="20" style="border-top: none;" width="105"&gt;07133AET5&lt;/TD&gt;&lt;TD class="xl69" style="border-top: none; border-left: none;" width="75"&gt;8/31/2013&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="48"&gt;8&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;75000000&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="111"&gt;0.015&lt;/TD&gt;&lt;TD class="xl63" style="border-top: none; border-left: none;" width="56"&gt;0.014&lt;/TD&gt;&lt;TD class="xl70" style="border-top: none; border-left: none;" width="93"&gt;$0&lt;/TD&gt;&lt;/TR&gt;&lt;/TBODY&gt;&lt;/TABLE&gt;&lt;P&gt;When&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 04 Feb 2013 04:45:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95634#M20133</guid>
      <dc:creator>toddtodd</dc:creator>
      <dc:date>2013-02-04T04:45:10Z</dc:date>
    </item>
    <item>
      <title>Re: SAS Macro Do Loop</title>
      <link>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95635#M20134</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Todd, &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I really recommend you read this paper:&lt;/P&gt;&lt;P&gt;&lt;A href="http://www2.sas.com/proceedings/sugi31/246-31.pdf" title="http://www2.sas.com/proceedings/sugi31/246-31.pdf"&gt;http://www2.sas.com/proceedings/sugi31/246-31.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As Art has mentioned, the datastep already loops through each record so you don't need a loop. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 04 Feb 2013 05:19:01 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/SAS-Macro-Do-Loop/m-p/95635#M20134</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2013-02-04T05:19:01Z</dc:date>
    </item>
  </channel>
</rss>

