<?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: wrong Stratum from ods output SurvivalPlot= dataset  from proc lifetest in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/wrong-Stratum-from-ods-output-SurvivalPlot-dataset-from-proc/m-p/880225#M43546</link>
    <description>&lt;P&gt;Show every bit of code that you ran between that Proc SQL (which would still be running for quite a while as&lt;/P&gt;
&lt;P&gt;SQL should terminate with QUIT; instead of RUN;) and that Proc Lifetest.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;On possibility is if you are in the habit of using code like the following then you may have had a logic error changing values.&lt;/P&gt;
&lt;PRE&gt;data data;
   set data;
/* manipulation goes here*/
run;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 12 Jun 2023 15:28:15 GMT</pubDate>
    <dc:creator>ballardw</dc:creator>
    <dc:date>2023-06-12T15:28:15Z</dc:date>
    <item>
      <title>wrong Stratum from ods output SurvivalPlot= dataset  from proc lifetest</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/wrong-Stratum-from-ods-output-SurvivalPlot-dataset-from-proc/m-p/880219#M43544</link>
      <description>&lt;P&gt;Hi, I have a data including trt variable and resp variable, below is the unique value.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sql;select distinct trt, resp from data;run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Sally_Caffrey_1-1686580936366.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/84900i681CC73EB853E6D3/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Sally_Caffrey_1-1686580936366.png" alt="Sally_Caffrey_1-1686580936366.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;Then I use this data to create survival data by proc lifetest, but the "survival" data from the ods output has a trt group that does not exist in the data, which looks very odd...&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc lifetest data=data timelist=(0 to 12 by 1) atrisk outsurv=surviv ;  
by trt  ;
time aval*cnsr(1);
strata resp  ;
ods output SurvivalPlot=survival ProductLimitEstimates=atrisk Quartiles=Quartiles;
run;&lt;BR /&gt;&lt;BR /&gt;proc sql;select distinct trt, Stratum, StratumNum from survival;run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Sally_Caffrey_2-1686581712266.png" style="width: 400px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/84901iB2CE48858EC114EB/image-size/medium?v=v2&amp;amp;px=400" role="button" title="Sally_Caffrey_2-1686581712266.png" alt="Sally_Caffrey_2-1686581712266.png" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;For trt=2, the resp changes to "PR(N=70)" instead of "PR(N=5)". It follows the trt=1...&lt;/P&gt;
&lt;P&gt;Does anyone knows why this wrong Stratum is output ? How to fix it ?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 12 Jun 2023 15:00:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/wrong-Stratum-from-ods-output-SurvivalPlot-dataset-from-proc/m-p/880219#M43544</guid>
      <dc:creator>Sally_Caffrey</dc:creator>
      <dc:date>2023-06-12T15:00:35Z</dc:date>
    </item>
    <item>
      <title>Re: wrong Stratum from ods output SurvivalPlot= dataset  from proc lifetest</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/wrong-Stratum-from-ods-output-SurvivalPlot-dataset-from-proc/m-p/880220#M43545</link>
      <description>You'll need to post your actual code and log for us to help out here. 99.9% of times this is user error, for example using different dat sets as input. &lt;BR /&gt;</description>
      <pubDate>Mon, 12 Jun 2023 15:03:28 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/wrong-Stratum-from-ods-output-SurvivalPlot-dataset-from-proc/m-p/880220#M43545</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2023-06-12T15:03:28Z</dc:date>
    </item>
    <item>
      <title>Re: wrong Stratum from ods output SurvivalPlot= dataset  from proc lifetest</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/wrong-Stratum-from-ods-output-SurvivalPlot-dataset-from-proc/m-p/880225#M43546</link>
      <description>&lt;P&gt;Show every bit of code that you ran between that Proc SQL (which would still be running for quite a while as&lt;/P&gt;
&lt;P&gt;SQL should terminate with QUIT; instead of RUN;) and that Proc Lifetest.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;On possibility is if you are in the habit of using code like the following then you may have had a logic error changing values.&lt;/P&gt;
&lt;PRE&gt;data data;
   set data;
/* manipulation goes here*/
run;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 12 Jun 2023 15:28:15 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/wrong-Stratum-from-ods-output-SurvivalPlot-dataset-from-proc/m-p/880225#M43546</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2023-06-12T15:28:15Z</dc:date>
    </item>
  </channel>
</rss>

