<?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: what that code does mean? in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259271#M50132</link>
    <description>&lt;P&gt;It looks like some sort of power analysis for (binomial) proportions. &amp;nbsp;But why reverse engineer this undocumented code? Understand the problem and write your own. And document it!&lt;/P&gt;</description>
    <pubDate>Sun, 27 Mar 2016 19:31:21 GMT</pubDate>
    <dc:creator>PGStats</dc:creator>
    <dc:date>2016-03-27T19:31:21Z</dc:date>
    <item>
      <title>what that code does mean?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259262#M50128</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;DATA covprob;
p = .5;
q = 1-p;
z=abs(probit(.025));
zz=z*z;
do n = 10 to 500;
w = zz / (2 * n);
rad = sqrt(2*w*p*q + w*w);
rt = (p + w + rad)/(1 +2*w);
lt = (p + w - rad)/(1 +2*w);
nhat_rt = floor(n*rt);
nhat_lt = ceil(n*lt - 1);
ncurl_rt = floor((n+4)*rt - 2);
ncurl_lt = ceil((n+4)*lt - 3);
p1 = probbnml(p, n, nhat_lt);
p2 = probbnml(p, n, nhat_rt);
cv_hat = p2 - p1;
p3 = probbnml(p, n, ncurl_lt);
p4 = probbnml(p, n, ncurl_rt);
cv_curl = p4 - p3;
output;
end;
keep n cv_hat cv_curl;
run;

&amp;nbsp;
&amp;nbsp;
PROC plot data = covprob;
plot cv_hat*n = '^';
plot cv_curl*n = '~';
run;
quit;
&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sun, 27 Mar 2016 18:02:20 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259262#M50128</guid>
      <dc:creator>bigban777</dc:creator>
      <dc:date>2016-03-27T18:02:20Z</dc:date>
    </item>
    <item>
      <title>Re: what that code does mean?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259267#M50129</link>
      <description>&lt;P&gt;In what context? Is there a specific part you don't understand?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Are you looking for an explanation of a specific line?&lt;/P&gt;
&lt;P&gt;Where did you find this code and what are you trying to do with it?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 27 Mar 2016 18:04:42 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259267#M50129</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-03-27T18:04:42Z</dc:date>
    </item>
    <item>
      <title>Re: what that code does mean?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259271#M50132</link>
      <description>&lt;P&gt;It looks like some sort of power analysis for (binomial) proportions. &amp;nbsp;But why reverse engineer this undocumented code? Understand the problem and write your own. And document it!&lt;/P&gt;</description>
      <pubDate>Sun, 27 Mar 2016 19:31:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259271#M50132</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2016-03-27T19:31:21Z</dc:date>
    </item>
    <item>
      <title>Re: what that code does mean?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259278#M50134</link>
      <description>&lt;P&gt;If it is power analysis it's likely proc power &amp;nbsp;would likely be a better implementation as well &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 27 Mar 2016 21:18:00 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259278#M50134</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2016-03-27T21:18:00Z</dc:date>
    </item>
    <item>
      <title>Re: what that code does mean?</title>
      <link>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259280#M50136</link>
      <description>That part:&lt;BR /&gt;nhat_rt = floor(n*rt);&lt;BR /&gt;nhat_lt = ceil(n*lt - 1);&lt;BR /&gt;ncurl_rt = floor((n+4)*rt - 2);&lt;BR /&gt;ncurl_lt = ceil((n+4)*lt - 3);&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;Is it interval? Why it is subtracte -1, -3</description>
      <pubDate>Sun, 27 Mar 2016 21:34:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/what-that-code-does-mean/m-p/259280#M50136</guid>
      <dc:creator>bigban777</dc:creator>
      <dc:date>2016-03-27T21:34:24Z</dc:date>
    </item>
  </channel>
</rss>

