<?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: Confidence interval with alpha = 0.01 in SAS Programming</title>
    <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456254#M115548</link>
    <description>&lt;P&gt;The mean difference of the variable Potassium between the cereals whose Manufacturer is General Mills and Kelloggs...&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Sun, 22 Apr 2018 02:10:24 GMT</pubDate>
    <dc:creator>Miah</dc:creator>
    <dc:date>2018-04-22T02:10:24Z</dc:date>
    <item>
      <title>Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456242#M115541</link>
      <description>&lt;P&gt;I am trying to&amp;nbsp;determine whether or not the mean of Potassium for the cereals whose manufacturer is General Mills or Kelloggs is different with a significance level of 0.01. I am having trouble getting the right observations selected, and therefore tusing PROC TTEST for the hypothesis test. Here it is my code and the data set:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;DATA cereal;&lt;BR /&gt;INFILE "/folders/myfolders/cereal.txt"&lt;BR /&gt;DLM=',' FIRSTOBS=2 DSD MISSOVER;&lt;BR /&gt;INPUT Name :$50. Manufacturer $ Type $ Calories Protein Sodium Fiber Carbohydrates Sugars Potassium Vitamins Weight Cups;&lt;BR /&gt;RUN;&lt;BR /&gt;&lt;BR /&gt;PROC PRINT DATA=cereal;&lt;BR /&gt;RUN; &lt;BR /&gt;&lt;BR /&gt;DATA cereal; &lt;BR /&gt;SET Cereal;&lt;BR /&gt;IF Manufacturer='General Mills' | Manufacturer='Kelloggs'; &lt;BR /&gt;RUN;&lt;BR /&gt;&lt;BR /&gt;PROC PRINT DATA=Cereal;&lt;BR /&gt;RUN; &lt;BR /&gt;&lt;BR /&gt;PROC TTEST DATA=Cereal ALPHA=0.01;&lt;BR /&gt;CLASS Manufacturer;&lt;BR /&gt;VAR Potassium;&lt;BR /&gt;RUN;&lt;BR /&gt;&lt;BR /&gt;PROC PRINT DATA=Cereal;&lt;BR /&gt;RUN; &lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 01:03:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456242#M115541</guid>
      <dc:creator>Miah</dc:creator>
      <dc:date>2018-04-22T01:03:37Z</dc:date>
    </item>
    <item>
      <title>Re: Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456246#M115543</link>
      <description>&lt;P&gt;What exactly is your question? Is there something wrong with the code?&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/194785"&gt;@Miah&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;I am trying to&amp;nbsp;determine whether or not the mean of Potassium for the cereals whose manufacturer is General Mills or Kelloggs is different with a significance level of 0.01. I am having trouble getting the right observations selected, and therefore tusing PROC TTEST for the hypothesis test. Here it is my code and the data set:&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;DATA cereal;&lt;BR /&gt;INFILE "/folders/myfolders/cereal.txt"&lt;BR /&gt;DLM=',' FIRSTOBS=2 DSD MISSOVER;&lt;BR /&gt;INPUT Name :$50. Manufacturer $ Type $ Calories Protein Sodium Fiber Carbohydrates Sugars Potassium Vitamins Weight Cups;&lt;BR /&gt;RUN;&lt;BR /&gt;&lt;BR /&gt;PROC PRINT DATA=cereal;&lt;BR /&gt;RUN; &lt;BR /&gt;&lt;BR /&gt;DATA cereal; &lt;BR /&gt;SET Cereal;&lt;BR /&gt;IF Manufacturer='General Mills' | Manufacturer='Kelloggs'; &lt;BR /&gt;RUN;&lt;BR /&gt;&lt;BR /&gt;PROC PRINT DATA=Cereal;&lt;BR /&gt;RUN; &lt;BR /&gt;&lt;BR /&gt;PROC TTEST DATA=Cereal ALPHA=0.01;&lt;BR /&gt;CLASS Manufacturer;&lt;BR /&gt;VAR Potassium;&lt;BR /&gt;RUN;&lt;BR /&gt;&lt;BR /&gt;PROC PRINT DATA=Cereal;&lt;BR /&gt;RUN; &lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 01:21:36 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456246#M115543</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-22T01:21:36Z</dc:date>
    </item>
    <item>
      <title>Re: Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456248#M115544</link>
      <description>&lt;P&gt;Yes. It is not generating the output that I need. I need&amp;nbsp;&lt;SPAN&gt;to&amp;nbsp;determine whether or not the mean of Potassium for the cereals whose manufacturer is General Mills or Kelloggs is different with a significance level of 0.01&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 01:25:30 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456248#M115544</guid>
      <dc:creator>Miah</dc:creator>
      <dc:date>2018-04-22T01:25:30Z</dc:date>
    </item>
    <item>
      <title>Re: Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456250#M115545</link>
      <description>&lt;P&gt;What exactly is your hypothesis?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Your current code tests, is the Potassium level between General Mills and Kelloggs cereals different.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/194785"&gt;@Miah&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;Yes. It is not generating the output that I need. I need&amp;nbsp;&lt;SPAN&gt;to&amp;nbsp;determine whether or not the mean of Potassium for the cereals whose manufacturer is General Mills or Kelloggs is different with a significance level of 0.01&amp;nbsp;&lt;/SPAN&gt;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 02:01:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456250#M115545</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-22T02:01:41Z</dc:date>
    </item>
    <item>
      <title>Re: Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456251#M115546</link>
      <description>&lt;P&gt;The H0 is whether or not the means are different.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 02:06:35 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456251#M115546</guid>
      <dc:creator>Miah</dc:creator>
      <dc:date>2018-04-22T02:06:35Z</dc:date>
    </item>
    <item>
      <title>Re: Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456253#M115547</link>
      <description>&lt;P&gt;Between what?&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/194785"&gt;@Miah&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;The H0 is whether or not the means are different.&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 02:08:26 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456253#M115547</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-22T02:08:26Z</dc:date>
    </item>
    <item>
      <title>Re: Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456254#M115548</link>
      <description>&lt;P&gt;The mean difference of the variable Potassium between the cereals whose Manufacturer is General Mills and Kelloggs...&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 02:10:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456254#M115548</guid>
      <dc:creator>Miah</dc:creator>
      <dc:date>2018-04-22T02:10:24Z</dc:date>
    </item>
    <item>
      <title>Re: Confidence interval with alpha = 0.01</title>
      <link>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456255#M115549</link>
      <description>&lt;P&gt;Ok, your code doesn't read the data in correctly. Check your data in Cereal data set, right after you import it.&lt;/P&gt;
&lt;P&gt;Run a PROC FREQ on the Manufacturer column.&lt;/P&gt;
&lt;P&gt;And read your log - does it show any errors for the code?&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Also, never ever code like this:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;data cereal;
set cereal;&lt;/CODE&gt;&lt;/PRE&gt;
&lt;P&gt;At this point you've destroyed your original data set and no longer have access to the original data, so you need to re-read it in from scratch which is fine in this case because your data is small. If it was a larger data set that would slow you down a lot each time.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Once you make those changes, it works as expected.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;BLOCKQUOTE&gt;&lt;HR /&gt;&lt;a href="https://communities.sas.com/t5/user/viewprofilepage/user-id/194785"&gt;@Miah&lt;/a&gt; wrote:&lt;BR /&gt;
&lt;P&gt;The mean difference of the variable Potassium between the cereals whose Manufacturer is General Mills and Kelloggs...&amp;nbsp;&lt;/P&gt;
&lt;HR /&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 22 Apr 2018 02:19:38 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Programming/Confidence-interval-with-alpha-0-01/m-p/456255#M115549</guid>
      <dc:creator>Reeza</dc:creator>
      <dc:date>2018-04-22T02:19:38Z</dc:date>
    </item>
  </channel>
</rss>

