<?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: Error: The CLASS Variable has more than two levels in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/587019#M167589</link>
    <description>&lt;P&gt;... then use&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc ttest data=import;
/* Neighborhoods values to be compared */
where neighborhood in ("First value", "Second value");
class neighborhood;
var sales_price; /* variable whose means will be compared */
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;to compare the levels of interest.&lt;/P&gt;</description>
    <pubDate>Sun, 08 Sep 2019 00:32:48 GMT</pubDate>
    <dc:creator>PGStats</dc:creator>
    <dc:date>2019-09-08T00:32:48Z</dc:date>
    <item>
      <title>Error: The CLASS Variable has more than two levels</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/587013#M167585</link>
      <description>&lt;P&gt;I am receiving the error that says the class variable has more than two levels, but i am pretty sure i only have two. Please help.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;PROC IMPORT DATAFILE=REFFILE&lt;BR /&gt;DBMS=CSV&lt;BR /&gt;OUT=WORK.IMPORT;&lt;BR /&gt;GETNAMES=YES;&lt;BR /&gt;RUN;&lt;/P&gt;&lt;P&gt;PROC CONTENTS DATA=WORK.IMPORT; RUN;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;%web_open_table(WORK.IMPORT);&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;DATA IMPORT;&lt;BR /&gt;infile '/folders/myfolders/sasuser.v94/nyc-rolling-sales.csv';&lt;BR /&gt;INPUT NEIGHBORHOOD $ Sales_Price;&lt;/P&gt;&lt;P&gt;proc ttest;&lt;/P&gt;&lt;P&gt;class neighborhood; /* defines the grouping variable */&lt;/P&gt;&lt;P&gt;var sales_price; /* variable whose means will be compared */&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;</description>
      <pubDate>Sat, 07 Sep 2019 23:25:13 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/587013#M167585</guid>
      <dc:creator>djcolantonio</dc:creator>
      <dc:date>2019-09-07T23:25:13Z</dc:date>
    </item>
    <item>
      <title>Re: Error: The CLASS Variable has more than two levels</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/587016#M167587</link>
      <description>&lt;P&gt;Run this to confirm how many levels:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc freq;
table neighborhood / missing;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Sat, 07 Sep 2019 23:36:47 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/587016#M167587</guid>
      <dc:creator>SASKiwi</dc:creator>
      <dc:date>2019-09-07T23:36:47Z</dc:date>
    </item>
    <item>
      <title>Re: Error: The CLASS Variable has more than two levels</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/587019#M167589</link>
      <description>&lt;P&gt;... then use&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;proc ttest data=import;
/* Neighborhoods values to be compared */
where neighborhood in ("First value", "Second value");
class neighborhood;
var sales_price; /* variable whose means will be compared */
run;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;to compare the levels of interest.&lt;/P&gt;</description>
      <pubDate>Sun, 08 Sep 2019 00:32:48 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/587019#M167589</guid>
      <dc:creator>PGStats</dc:creator>
      <dc:date>2019-09-08T00:32:48Z</dc:date>
    </item>
    <item>
      <title>Re: Error: The CLASS Variable has more than two levels</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/621168#M182571</link>
      <description>&lt;P&gt;I am getting the same error. I am having trouble posting my question. Why do I keep getting the error "the class variable has more than two levels"?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;My code:&lt;/P&gt;&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data name;
	input one two @@;
	cards;
	16.03 16.02 16.04 15.97 16.05 15.96 16.05 16.01 16.02 15.99
	16.01 16.03 15.96 16.04 15.98 16.02 16.02 16.01 15.99 16.00
	;
proc ttest data=name;
	class one;
	var two;
run;&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Thu, 30 Jan 2020 15:04:59 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Error-The-CLASS-Variable-has-more-than-two-levels/m-p/621168#M182571</guid>
      <dc:creator>abudyak</dc:creator>
      <dc:date>2020-01-30T15:04:59Z</dc:date>
    </item>
  </channel>
</rss>

