<?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: Adding to PROC REPORT in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Adding-to-PROC-REPORT/m-p/704398#M79949</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I believe you are having this issue because you are keeping the variable 'Statistic' in your Data step but in your Proc Report step, you are referring to 'Test' when you actually mean 'Statistic'. If you would like for the statistic variable to be renamed test, you could use a Define statement. I hope my code below helps!&lt;/P&gt;&lt;PRE&gt;PROC REPORT DATA = HypRslt.chisqresults  ;&lt;BR /&gt;	COLUMN	Statistic&lt;BR /&gt;	("Statistical Results"     DF  Value Prob );&lt;BR /&gt;	DEFINE  Statistic   /  'Test';&lt;BR /&gt;	DEFINE  Value       /  Format= 4.2;&lt;BR /&gt;	DEFINE  Prob        /  Format= 4.2 'P-Value';&lt;BR /&gt;	RUN;		&lt;/PRE&gt;</description>
    <pubDate>Tue, 08 Dec 2020 13:50:25 GMT</pubDate>
    <dc:creator>James18</dc:creator>
    <dc:date>2020-12-08T13:50:25Z</dc:date>
    <item>
      <title>Adding to PROC REPORT</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Adding-to-PROC-REPORT/m-p/704362#M79947</link>
      <description>&lt;P&gt;Hi, I am attempting to create this table in an ODS report for my Chi-Square results and I want to include the test name 'Chi-Square' under the column 'Test' in the table. However, I keep getting a blank cell beneath 'Test' in my table and I'm unsure how to alter my code to fix this. This is the code I am currently working with:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;DATA ChiSqResults;
	SET ChiSqResults;
	KEEP STATISTIC DF VALUE PROB;
	LABEL Prob = "P-Value";
	IF STATISTIC = "Chi-Square";
		VALUE = ROUND(VALUE, 0.01);
		Prob = ROUND(PROB, 0.01);
	FORMAT VALUE F12.2
		Prob F12.2;
	RUN;

TITLE1 BOLD	'Chi-Square Test of Independence Results';
FOOTNOTE	"Created by HS";
PROC REPORT DATA = ChiSqResults;
	COLUMN	Test 
		("Statistical Results" DF Value Prob);
	LABEL Prob = 'P-Value';
	
	RUN;
TITLE;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;</description>
      <pubDate>Thu, 10 Dec 2020 15:13:23 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Adding-to-PROC-REPORT/m-p/704362#M79947</guid>
      <dc:creator>hswdl01</dc:creator>
      <dc:date>2020-12-10T15:13:23Z</dc:date>
    </item>
    <item>
      <title>Re: Adding to PROC REPORT</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Adding-to-PROC-REPORT/m-p/704398#M79949</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I believe you are having this issue because you are keeping the variable 'Statistic' in your Data step but in your Proc Report step, you are referring to 'Test' when you actually mean 'Statistic'. If you would like for the statistic variable to be renamed test, you could use a Define statement. I hope my code below helps!&lt;/P&gt;&lt;PRE&gt;PROC REPORT DATA = HypRslt.chisqresults  ;&lt;BR /&gt;	COLUMN	Statistic&lt;BR /&gt;	("Statistical Results"     DF  Value Prob );&lt;BR /&gt;	DEFINE  Statistic   /  'Test';&lt;BR /&gt;	DEFINE  Value       /  Format= 4.2;&lt;BR /&gt;	DEFINE  Prob        /  Format= 4.2 'P-Value';&lt;BR /&gt;	RUN;		&lt;/PRE&gt;</description>
      <pubDate>Tue, 08 Dec 2020 13:50:25 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Adding-to-PROC-REPORT/m-p/704398#M79949</guid>
      <dc:creator>James18</dc:creator>
      <dc:date>2020-12-08T13:50:25Z</dc:date>
    </item>
    <item>
      <title>Re: Adding to PROC REPORT</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Adding-to-PROC-REPORT/m-p/704466#M79951</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;It looks like 'Test' in your code should be replaced with Statistic, as that is where the Chi-Square option is held. Using DEFINE, as shown below, should solve your problem!&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;PROC REPORT DATA = dataset.ChiSqResults;
COLUMN Statistic ("Statistical Results" DF Value Prob );
DEFINE Statistic / 'Test';
DEFINE Prob / 'P-Value' FORMAT = 4.2 ;
DEFINE Value / FORMAT = 4.2;
FOOTNOTE "Created by HS";
RUN;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 10 Dec 2020 15:11:11 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Adding-to-PROC-REPORT/m-p/704466#M79951</guid>
      <dc:creator>kaitlineolson7</dc:creator>
      <dc:date>2020-12-10T15:11:11Z</dc:date>
    </item>
  </channel>
</rss>

