<?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: Output covariates from proc phreg not working in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272889#M58403</link>
    <description>&lt;P&gt;Thank you Rick. I never knew about the proc plm. I am trying it out. I am wondering for proc phreg, can proc plm be used for the diagram attached where I am trying to model the ln(hazard ratio) versus age?&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/12579iE21B9A2FAE404713/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="Capture.PNG" title="Capture.PNG" /&gt;</description>
    <pubDate>Tue, 24 May 2016 21:15:57 GMT</pubDate>
    <dc:creator>lei</dc:creator>
    <dc:date>2016-05-24T21:15:57Z</dc:date>
    <item>
      <title>Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272824#M58391</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm running the codes below in order get an output of the covariates. However, I keep on getting the error below.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PROC PHREG DATA=CRC.FINAL10;&lt;BR /&gt; MODEL DAYS_BTWN_SURG1DEATH*DIED(0)=WAIT1 FEMALE AGE STAGECATUNK STAGECAT3 COMORMISS1 CHEMO_NUMCAT /RL;&lt;BR /&gt; BASELINE OUT=YROUT LOWER=LOW_CI UPPER=UP_CI COVARIATES=SAMPLE SURVIVAL=SURV/ALPHA=0.05 NOMEAN;&lt;BR /&gt;RUN;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ERROR: File WORK.SAMPLE.DATA does not exist.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does anyone know why this is happening?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Shirley&lt;/P&gt;</description>
      <pubDate>Tue, 24 May 2016 18:28:10 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272824#M58391</guid>
      <dc:creator>lei</dc:creator>
      <dc:date>2016-05-24T18:28:10Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272833#M58392</link>
      <description>&lt;P&gt;The COVARIATES= option on the BASELINE statement is supposed to point to a SAS data set. The error is saying that the data set WORK.Sample does not exist.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;By the way, I assume that FEMALE is a categorical variable. If so, you might want to add&amp;nbsp;FEMALE to a CLASS statement. If there are other classification variables in the model, those should also be added to the CLASS statement.&lt;/P&gt;</description>
      <pubDate>Tue, 24 May 2016 18:37:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272833#M58392</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2016-05-24T18:37:22Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272834#M58393</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;All the categorical variables have been converted to dummy. Would this affect the output?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I understand that it says the work.sample does not exist. Is it suppose to create the datasest work if it doesn't exist in this case? or am I suppose to create it first?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 May 2016 18:38:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272834#M58393</guid>
      <dc:creator>lei</dc:creator>
      <dc:date>2016-05-24T18:38:54Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272844#M58395</link>
      <description>&lt;P&gt;You are supposed to create it. The &lt;A href="http://support.sas.com/documentation/cdl//en/statug/68162/HTML/default/viewer.htm#statug_phreg_gettingstarted.htm" target="_self"&gt;"Getting Started" &amp;nbsp;example in the doc&lt;/A&gt;&amp;nbsp;shows what should be in the data set. You can also omit that option. In that case,&amp;nbsp;the proc will output the requested statistics at&amp;nbsp;the reference levels for the CLASS variables and at the mean value the continuous variables.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would advise using the CLASS statement. As you see from the previous paragraph, the BASELINE statement treats CLASS and continuous variables differently. &amp;nbsp;If "males" are the reference level, then&lt;/P&gt;
&lt;P&gt;1) If FEMALE is a class variable, then the output statistics will be generated for the reference level, perhaps FEMALE=0.&lt;/P&gt;
&lt;P&gt;2) If FEMALE is a continuous variable, then the output statistics will be generated for the average level, which could be 0.5 or some other fractional value. &amp;nbsp;Evaluating the model at FEMALE=0.5&amp;nbsp;is probably not what you want.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 May 2016 18:55:54 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272844#M58395</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2016-05-24T18:55:54Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272872#M58400</link>
      <description>&lt;P&gt;Hi Rick,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thank you so much. I see what you mean. I also got it to work. However, I'm trying to&amp;nbsp;recreate Figure 2 from the SAS proceeding &lt;A href="http://support.sas.com/resources/papers/proceedings09/236-2009.pdf" target="_blank"&gt;http://support.sas.com/resources/papers/proceedings09/236-2009.pdf&lt;/A&gt; . Figure 2 is on page 6 and titled "&amp;nbsp;Visualizing the impact of age (years) as continuous covariate on estimated 5-years primary outcome with 95% confidence interval by gender group.". I am not getting the graph at all.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Does anyone know how they to re-produce the figure?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Thanks.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 24 May 2016 20:07:17 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272872#M58400</guid>
      <dc:creator>lei</dc:creator>
      <dc:date>2016-05-24T20:07:17Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272879#M58402</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Well, you could do it by hand like they do, but if you are using a modern version of SAS, try this:&lt;/P&gt;
&lt;P&gt;1) Use &lt;A href="http://blogs.sas.com/content/iml/2014/02/19/scoring-a-regression-model-in-sas.html" target="_self"&gt;the STORE statement&lt;/A&gt; in PROC PHREG to write the model to an item store.&lt;/P&gt;
&lt;P&gt;2) Use the &lt;A href="http://support.sas.com/documentation/cdl/en/statug/68162/HTML/default/viewer.htm#statug_introcom_sect025.htm" target="_self"&gt;EFFECTPLOT statement in PROC PLM&lt;/A&gt; to create the plot. The doc shows many examples. their examlp[e might look something like this (untested)&lt;/P&gt;
&lt;P&gt;effectplot slicefit(x=age sliceby=sex);&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;For more complex models, you'll want to use the AT= option on the EFFECTPLOT statement to specify the value for the other independent variables. &amp;nbsp;For additional examples, &lt;A href="http://www.mwsug.org/proceedings/2013/AA/MWSUG-2013-AA08.pdf" target="_self"&gt;see Downer 2013.&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 24 May 2016 20:27:55 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272879#M58402</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2016-05-24T20:27:55Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272889#M58403</link>
      <description>&lt;P&gt;Thank you Rick. I never knew about the proc plm. I am trying it out. I am wondering for proc phreg, can proc plm be used for the diagram attached where I am trying to model the ln(hazard ratio) versus age?&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/12579iE21B9A2FAE404713/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="Capture.PNG" title="Capture.PNG" /&gt;</description>
      <pubDate>Tue, 24 May 2016 21:15:57 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272889#M58403</guid>
      <dc:creator>lei</dc:creator>
      <dc:date>2016-05-24T21:15:57Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272903#M58406</link>
      <description>&lt;P&gt;Hi Rick,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here's my model:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;PROC PHREG DATA = CRC.FINAL10;&lt;BR /&gt; CLASS&amp;nbsp;STAGE2 (ref='II')/PARAM=REFERENCE; &lt;BR /&gt; MODEL DAYS_BTWN_SURG1DEATH*DIED(0) = WAIT1 STAGE2;&lt;BR /&gt; STORE OUT=CRC.WAIT_SURVIVAL;&lt;BR /&gt;RUN;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ODS GRAPHICS ON;&lt;BR /&gt;PROC PLM RESTORE=CRC.WAIT_SURVIVAL;&lt;BR /&gt; EFFECTPLOT SLICEFIT(X=WAIT1 SLICEBY=STAGE2); &lt;BR /&gt;RUN;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I got the graph below. It doesn't look right. I'm really sorry. I have never used proc plm am a little confused by it.&lt;/P&gt;&lt;BR /&gt;&lt;IMG src="https://communities.sas.com/t5/image/serverpage/image-id/12580iEB77445B8E29D655/image-size/large?v=1.0&amp;amp;px=600" border="0" alt="kkk.png" title="kkk.png" /&gt;</description>
      <pubDate>Tue, 24 May 2016 22:26:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272903#M58406</guid>
      <dc:creator>lei</dc:creator>
      <dc:date>2016-05-24T22:26:37Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272907#M58407</link>
      <description>&lt;P&gt;'m sure that by reading the doc and experimenting you'll have the plot you want very soon.&amp;nbsp; Good luck.&lt;/P&gt;</description>
      <pubDate>Tue, 24 May 2016 22:45:22 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/272907#M58407</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2016-05-24T22:45:22Z</dc:date>
    </item>
    <item>
      <title>Re: Output covariates from proc phreg not working</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/273832#M58481</link>
      <description>&lt;P&gt;Got it thank you!&lt;/P&gt;</description>
      <pubDate>Mon, 30 May 2016 00:07:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Output-covariates-from-proc-phreg-not-working/m-p/273832#M58481</guid>
      <dc:creator>lei</dc:creator>
      <dc:date>2016-05-30T00:07:49Z</dc:date>
    </item>
  </channel>
</rss>

