<?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: Restricted cubic splines in Multivarate Linear Regression in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Restricted-cubic-splines-in-Multivarate-Linear-Regression/m-p/808357#M39765</link>
    <description>&lt;P&gt;The first question in my mind is about the macro code RCS_Reg.sas. What is going on with it? Without access to that code, I don't see how we can help you accomplish what you want.&amp;nbsp; Perhaps we could use PROC TPSPLINE, or the EFFECT and EFFECTPLOT commands in one of the PROC's which support them, such as GENMOD. Something like the second example in the EFFECTPLOT documentation might serve as an example.&amp;nbsp; The reason I am jumping to that example is that you get a plot of the dependent variable as a function of the other variables, rather than a plot of the difference as a function of one of the variables.&amp;nbsp; The issue with that particular approach is how to deal with the other variables in the model. So, I get to using PROC SGPLOT, with the PBSPLINE statement.&amp;nbsp; Try something like:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sgplot data=sashelp.gas;
   pbspline y=log_valu x=meat / nknots=3;
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;SteveDenham&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 18 Apr 2022 17:10:12 GMT</pubDate>
    <dc:creator>SteveDenham</dc:creator>
    <dc:date>2022-04-18T17:10:12Z</dc:date>
    <item>
      <title>Restricted cubic splines in Multivarate Linear Regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Restricted-cubic-splines-in-Multivarate-Linear-Regression/m-p/808146#M39762</link>
      <description>&lt;P&gt;Hello everyone,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am new to SAS. I want to assess the association between&amp;nbsp;meat intake and **bleep** quality parameters by using restricted cubic splines in Multivarate Linear Regression.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I used the following syntax for Multivarate Linear Regression.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=""&gt;%include&amp;nbsp;"F:\sas\nonlinear_curve\RCS_Reg.sas";

%RCS_Reg(infile=fenxi_4_1, Main_spline_var=meat, ref_val=0, typ_reg=lin, dep_var=Log_volu,

Oth_spline_var1=A_age, Oth_spline_var2=BMI, Oth_spline_var3=I_tvdur, Oth_spline_var4=I_pa, Oth_spline_var5=f_en,Oth_spline_var6=factor1, Oth_splin&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Graph1.png" style="width: 882px;"&gt;&lt;img src="https://communities.sas.com/t5/image/serverpage/image-id/70481iFDCF207F9B1AB39D/image-size/large?v=v2&amp;amp;px=999" role="button" title="Graph1.png" alt="Graph1.png" /&gt;&lt;/span&gt;e_var7=factor2, Oth_spline_var8=factor3, Oth_spline_var9=factor4, Oth_spline_var10=factor5,

adjust_var=O_ad smoke income,

avk_msv=0,&amp;nbsp;knots_msv=5&amp;nbsp;50&amp;nbsp;95,x_ref_line=0,y_ref_line=1,specif_val=46.19&amp;nbsp;130.975&amp;nbsp;243.14,no_title=1,no_label_x=1,no_label_y=1,no_legend=1,display_knots=1);

quit;

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Generate&amp;nbsp;"Graph 1" after running.&amp;nbsp;&amp;nbsp;Y_AXIS list the Log_volu "Difference [95%]" for values of meat.&amp;nbsp;&amp;nbsp;However, I want see the&amp;nbsp;Y_AXIS that&amp;nbsp;list the&amp;nbsp;values of Log_volu for values of meat in my SAS output.&amp;nbsp;I was wondering if anyone can help me with the syntax.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Thank you in advance!&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Apr 2022 08:33:04 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Restricted-cubic-splines-in-Multivarate-Linear-Regression/m-p/808146#M39762</guid>
      <dc:creator>Toughguy</dc:creator>
      <dc:date>2022-04-16T08:33:04Z</dc:date>
    </item>
    <item>
      <title>Re: Restricted cubic splines in Multivarate Linear Regression</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Restricted-cubic-splines-in-Multivarate-Linear-Regression/m-p/808357#M39765</link>
      <description>&lt;P&gt;The first question in my mind is about the macro code RCS_Reg.sas. What is going on with it? Without access to that code, I don't see how we can help you accomplish what you want.&amp;nbsp; Perhaps we could use PROC TPSPLINE, or the EFFECT and EFFECTPLOT commands in one of the PROC's which support them, such as GENMOD. Something like the second example in the EFFECTPLOT documentation might serve as an example.&amp;nbsp; The reason I am jumping to that example is that you get a plot of the dependent variable as a function of the other variables, rather than a plot of the difference as a function of one of the variables.&amp;nbsp; The issue with that particular approach is how to deal with the other variables in the model. So, I get to using PROC SGPLOT, with the PBSPLINE statement.&amp;nbsp; Try something like:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc sgplot data=sashelp.gas;
   pbspline y=log_valu x=meat / nknots=3;
run;
&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;SteveDenham&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Apr 2022 17:10:12 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Restricted-cubic-splines-in-Multivarate-Linear-Regression/m-p/808357#M39765</guid>
      <dc:creator>SteveDenham</dc:creator>
      <dc:date>2022-04-18T17:10:12Z</dc:date>
    </item>
  </channel>
</rss>

