<?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 Proc lifetest question in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822276#M40693</link>
    <description>&lt;P&gt;I used two method trying to get&amp;nbsp;quartile estimates: one is using weight statement and another is not. I realize the results are a little differenct.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below is my code and results.&lt;/P&gt;
&lt;P&gt;Can someone help me figure out why it is different, which result is correct, and how to make the results same. Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data x1;
wgt=1;arm=1;
input subjid aval cnsr;
datalines;
1 3.2 0
2 3.7 0
3 6.4 0
4 7.2 0
5 7.3 1
6 9.1 0
7 9.1 1
8 9.2 0
9 11.4 0
10 13.6 0
;

proc lifetest data=x1 ;
time AVAL*CNSR (1);
strata arm/adjust=tukey;
run;
proc lifetest data=x1 ;
weight wgt;
time AVAL*CNSR (1);
strata arm/adjust=tukey;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below is the result without weight statement.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.JPG" style="width: 491px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73062i92DCB68A75D21387/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.JPG" alt="Capture.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below is the result with weight statement.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture2.JPG" style="width: 495px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73063i1214F202842D2AEC/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture2.JPG" alt="Capture2.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Fri, 08 Jul 2022 13:54:29 GMT</pubDate>
    <dc:creator>Niugg2010</dc:creator>
    <dc:date>2022-07-08T13:54:29Z</dc:date>
    <item>
      <title>Proc lifetest question</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822276#M40693</link>
      <description>&lt;P&gt;I used two method trying to get&amp;nbsp;quartile estimates: one is using weight statement and another is not. I realize the results are a little differenct.&amp;nbsp;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below is my code and results.&lt;/P&gt;
&lt;P&gt;Can someone help me figure out why it is different, which result is correct, and how to make the results same. Thanks&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data x1;
wgt=1;arm=1;
input subjid aval cnsr;
datalines;
1 3.2 0
2 3.7 0
3 6.4 0
4 7.2 0
5 7.3 1
6 9.1 0
7 9.1 1
8 9.2 0
9 11.4 0
10 13.6 0
;

proc lifetest data=x1 ;
time AVAL*CNSR (1);
strata arm/adjust=tukey;
run;
proc lifetest data=x1 ;
weight wgt;
time AVAL*CNSR (1);
strata arm/adjust=tukey;
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below is the result without weight statement.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture.JPG" style="width: 491px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73062i92DCB68A75D21387/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture.JPG" alt="Capture.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Below is the result with weight statement.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Capture2.JPG" style="width: 495px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/73063i1214F202842D2AEC/image-size/large?v=v2&amp;amp;px=999" role="button" title="Capture2.JPG" alt="Capture2.JPG" /&gt;&lt;/span&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 08 Jul 2022 13:54:29 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822276#M40693</guid>
      <dc:creator>Niugg2010</dc:creator>
      <dc:date>2022-07-08T13:54:29Z</dc:date>
    </item>
    <item>
      <title>Re: Proc lifetest question</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822309#M40694</link>
      <description>Sometimes using WEIGHT=1 for all observations can produce an error.   I would try the FREQ statement.&lt;BR /&gt;</description>
      <pubDate>Fri, 08 Jul 2022 15:56:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822309#M40694</guid>
      <dc:creator>OsoGris</dc:creator>
      <dc:date>2022-07-08T15:56:39Z</dc:date>
    </item>
    <item>
      <title>Re: Proc lifetest question</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822340#M40699</link>
      <description>&lt;P&gt;Thanks. I tried FREQ statement and it produced the same results.&lt;/P&gt;
&lt;P&gt;I using Weight statement, becuase sometime all group censor varlue is 1, if without weight the code will produce warnings:&lt;BR /&gt;WARNING: The likelihood ratio test for strata homogeneity is questionable since some strata have no events.&lt;BR /&gt;Like below example: if without Weight statment or Freq statement, both produce WARNING&lt;/P&gt;
&lt;P&gt;if with Weight statement, there is no warning. but the result is different from others.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data x1;
wgt=1;
input subjid arm aval cnsr;
datalines;
1 1 3.2 0
2 1 3.7 0
3 1 6.4 0
4 1 7.2 0
5 1 7.3 1
6 1 9.1 0
7 1 9.1 1
8 1 9.2 0
9 1 11.4 0
10 1 13.6 0
5 2 2.3 1
6 2 3.1 1
7 2 6.1 1
8 2 5.2 1
9 2 12.4 1
10 2 11.6 1
;

proc lifetest data=x1 ;
time AVAL*CNSR (1);
strata arm/adjust=tukey;
run;
proc lifetest data=x1 ;
weight wgt;
time AVAL*CNSR (1);
strata arm/adjust=tukey;
run;

proc lifetest data=x1 ;
freq wgt;
time AVAL*CNSR (1);
strata arm/adjust=tukey;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 08 Jul 2022 19:03:33 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822340#M40699</guid>
      <dc:creator>Niugg2010</dc:creator>
      <dc:date>2022-07-08T19:03:33Z</dc:date>
    </item>
    <item>
      <title>Re: Proc lifetest question</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822342#M40700</link>
      <description>&lt;P&gt;By the way, can you please give me some details, in what conditions Weight statement may produce errors? Since I used Weight statement a lot, and nerver realize this issue.&amp;nbsp; Thanks&lt;/P&gt;</description>
      <pubDate>Fri, 08 Jul 2022 19:05:51 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Proc-lifetest-question/m-p/822342#M40700</guid>
      <dc:creator>Niugg2010</dc:creator>
      <dc:date>2022-07-08T19:05:51Z</dc:date>
    </item>
  </channel>
</rss>

