<?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 Renaming a Column in Proc Freq in New SAS User</title>
    <link>https://communities.sas.com/t5/New-SAS-User/Renaming-a-Column-in-Proc-Freq/m-p/703537#M26044</link>
    <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to create a SAS output table using PROC FREQ, and I only want the Test, DF, Value, and Prob columns. However, I need to rename the prob column to P-Value. Whenever I run the code below, I receive an error saying that the variable Prob does not exist.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ODS OUTPUT ChiSq = ChiSqResults (DROP = Table WHERE = (Statistic = 'Chi-Square') RENAME = (Prob = P-Value);&lt;BR /&gt;PROC FREQ DATA = HypAnalysis2;&lt;BR /&gt;TABLES HypRelDeathInd*StateCd / NOCUM NOCOL NOROW NOPERCENT CHISQ;&lt;BR /&gt;RUN;&lt;/P&gt;&lt;P&gt;PROC PRINT DATA = ChiSqResults NOOBS;&lt;BR /&gt;RUN;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would appreciate any help! Thank you.&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 10 Dec 2020 15:04:52 GMT</pubDate>
    <dc:creator>ssills24</dc:creator>
    <dc:date>2020-12-10T15:04:52Z</dc:date>
    <item>
      <title>Renaming a Column in Proc Freq</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Renaming-a-Column-in-Proc-Freq/m-p/703537#M26044</link>
      <description>&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am trying to create a SAS output table using PROC FREQ, and I only want the Test, DF, Value, and Prob columns. However, I need to rename the prob column to P-Value. Whenever I run the code below, I receive an error saying that the variable Prob does not exist.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;ODS OUTPUT ChiSq = ChiSqResults (DROP = Table WHERE = (Statistic = 'Chi-Square') RENAME = (Prob = P-Value);&lt;BR /&gt;PROC FREQ DATA = HypAnalysis2;&lt;BR /&gt;TABLES HypRelDeathInd*StateCd / NOCUM NOCOL NOROW NOPERCENT CHISQ;&lt;BR /&gt;RUN;&lt;/P&gt;&lt;P&gt;PROC PRINT DATA = ChiSqResults NOOBS;&lt;BR /&gt;RUN;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I would appreciate any help! Thank you.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 10 Dec 2020 15:04:52 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Renaming-a-Column-in-Proc-Freq/m-p/703537#M26044</guid>
      <dc:creator>ssills24</dc:creator>
      <dc:date>2020-12-10T15:04:52Z</dc:date>
    </item>
    <item>
      <title>Re: Renaming a Column in Proc Freq</title>
      <link>https://communities.sas.com/t5/New-SAS-User/Renaming-a-Column-in-Proc-Freq/m-p/703555#M26048</link>
      <description>&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/344233"&gt;@ssills24&lt;/a&gt;&amp;nbsp;wrote:&lt;BR /&gt;
&lt;P&gt;Hello,&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am trying to create a SAS output table using PROC FREQ, and I only want the Test, DF, Value, and Prob columns. However, I need to rename the prob column to P-Value. Whenever I run the code below, I receive an error saying that the variable Prob does not exist.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;ODS OUTPUT ChiSq = HypRslt.ChiSqResults (DROP = Table WHERE = (Statistic = 'Chi-Square') RENAME = (Prob = P-Value);&lt;BR /&gt;PROC FREQ DATA = HypAnl.HypAnalysis2;&lt;BR /&gt;TABLES HypRelDeathInd*StateCd / NOCUM NOCOL NOROW NOPERCENT CHISQ;&lt;BR /&gt;RUN;&lt;/P&gt;
&lt;P&gt;PROC PRINT DATA = HypRslt.ChiSqResults NOOBS;&lt;BR /&gt;RUN;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I would appreciate any help! Thank you.&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;The code should generate more error messages than the one you are mentioning. Also note that "P-Value" is not a valid name for a sas variable. If you need to have "P-Value" as heading when printing the dataset, use a label:&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc print data = hyprslt.chisqresults noobs label;
  label prob = 'P-Value';
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Fri, 04 Dec 2020 05:45:14 GMT</pubDate>
      <guid>https://communities.sas.com/t5/New-SAS-User/Renaming-a-Column-in-Proc-Freq/m-p/703555#M26048</guid>
      <dc:creator>andreas_lds</dc:creator>
      <dc:date>2020-12-04T05:45:14Z</dc:date>
    </item>
  </channel>
</rss>

