<?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 Turn off kernel line in proc ttest? in Statistical Procedures</title>
    <link>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/413651#M21696</link>
    <description>&lt;P&gt;Is there a way to suppress the red kernel line when running a proc ttest? My google-fu is coming up short here.&lt;/P&gt;</description>
    <pubDate>Wed, 15 Nov 2017 13:48:37 GMT</pubDate>
    <dc:creator>TheShark</dc:creator>
    <dc:date>2017-11-15T13:48:37Z</dc:date>
    <item>
      <title>Turn off kernel line in proc ttest?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/413651#M21696</link>
      <description>&lt;P&gt;Is there a way to suppress the red kernel line when running a proc ttest? My google-fu is coming up short here.&lt;/P&gt;</description>
      <pubDate>Wed, 15 Nov 2017 13:48:37 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/413651#M21696</guid>
      <dc:creator>TheShark</dc:creator>
      <dc:date>2017-11-15T13:48:37Z</dc:date>
    </item>
    <item>
      <title>Re: Turn off kernel line in proc ttest?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/413675#M21698</link>
      <description>&lt;P&gt;I don't think you can do that by using the TTEST syntax.&amp;nbsp;I think you would have to&amp;nbsp;modify the underlying template (such as&amp;nbsp;Stat.TTest.Graphics.Summary2 for the two-sample test) and delete (or comment out) the DENSITYPLOT statements that create the kernel curves. For an overview and examples, see &lt;A href="http://go.documentation.sas.com/?docsetId=statug&amp;amp;docsetTarget=statug_templt_toc.htm&amp;amp;docsetVersion=14.3&amp;amp;locale=en" target="_self"&gt;the "Template Modification" chapter in the SAS/STAT documentation.&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Here's how you can do it for the two-sample t test:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;&lt;CODE class=" language-sas"&gt;/* redefine template used by PROC TTEST to define summary panel */&lt;BR /&gt;proc template;
define statgraph Stat.TTest.Graphics.Summary2;
   notes
      "Comparative histograms with normal/kernel densities and
 boxplots,             (two-sample)";
   dynamic _Y1 _Y2 _Y _VARNAME _XLAB _SHORTXLAB _CLASS1 _CLASS2
      _CLASSNAME _LOGNORMAL _OBSVAR _byline_ _bytitle_
      _byfootnote_;
   BeginGraph;
      entrytitle "Distribution of " _VARNAME;
      layout lattice / rows=3 columns=1 columndatarange=
         unionall rowweights=(.4 .4 .2) shrinkfonts=true;
         columnaxes;
            columnaxis / display=(ticks tickvalues label) label
               =_XLAB shortlabel=_SHORTXLAB griddisplay=auto_on;
         endcolumnaxes;
         layout overlay / xaxisopts=(display=none);
            histogram _Y1 / binaxis=false primary=true;
            if (
               (NOT EXISTS(_LOGNORMAL)) AND
 (NOT(EXISTS(_PAIRED) AND EXISTS(_RATIO))))
               densityplot _Y1 / normal () name="Normal"
                  legendlabel="Normal" lineattrs=GRAPHFIT;
            endif;
            /*
            densityplot _Y1 / kernel () name="Kernel"
               legendlabel="Kernel" lineattrs=GRAPHFIT2;
            */
            entry _CLASS1 / autoalign=(topleft topright top);
         endlayout;
         layout overlay / xaxisopts=(display=none);
            histogram _Y2 / binaxis=false primary=true;
            if (
               (NOT EXISTS(_LOGNORMAL)) AND
 (NOT(EXISTS(_PAIRED) AND EXISTS(_RATIO))))
               densityplot _Y2 / normal () name="Normal"
                  legendlabel="Normal" lineattrs=GRAPHFIT;
            endif;
            /*
            densityplot _Y2 / kernel () name="Kernel"
               legendlabel="Kernel" lineattrs=GRAPHFIT2;
            */
            entry _CLASS2 / autoalign=(topleft topright top);
         endlayout;
         columnheaders;
            layout gridded / shrinkfonts=true;
               discreteLegend "Normal" "Kernel" / across=4
                  BackgroundColor=GraphWalls:Color Opaque=true;
            endlayout;
         endcolumnheaders;
         layout overlay / xaxisopts=(display=none) yaxisopts=(
            label=_CLASSNAME reverse=true);
            if (EXISTS(_LOGNORMAL))
               boxplot X=CLASS Y=_Y / orient=horizontal display
                  =(caps fill median outliers);
            else
               boxplot X=CLASS Y=_Y / orient=horizontal;
            endif;
         endlayout;
         columnheaders;
            layout gridded / shrinkfonts=true;
               discreteLegend "Normal" "Kernel" / across=4
                  BackgroundColor=GraphWalls:Color Opaque=true;
            endlayout;
         endcolumnheaders;
      endlayout;
      if (_BYTITLE_)
         entrytitle _BYLINE_ / textattrs=GRAPHVALUETEXT;
      else
         if (_BYFOOTNOTE_)
            entryfootnote halign=left _BYLINE_;
         endif;
      endif;
   EndGraph;
end;


proc ttest data=sashelp.class;
class sex;
var height;
run;

/* to restore the original template, run the following */
/*
proc template;
   delete Stat.TTest.Graphics.Summary2 / store=sasuser.templat;
run;
*/&lt;/CODE&gt;&lt;/PRE&gt;</description>
      <pubDate>Wed, 15 Nov 2017 15:09:41 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/413675#M21698</guid>
      <dc:creator>Rick_SAS</dc:creator>
      <dc:date>2017-11-15T15:09:41Z</dc:date>
    </item>
    <item>
      <title>Re: Turn off kernel line in proc ttest?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/413676#M21699</link>
      <description>&lt;P&gt;I assume you are talking about the histogram produced by PROC TTEST. But I don't think so.&amp;nbsp;You can of course edit the template that PROC TTEST uses,&amp;nbsp;though a similar plot is probably easier to create using PROC UNIVARIATE or PROC SGPLOT.&lt;/P&gt;</description>
      <pubDate>Wed, 15 Nov 2017 15:14:49 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/413676#M21699</guid>
      <dc:creator>PeterClemmensen</dc:creator>
      <dc:date>2017-11-15T15:14:49Z</dc:date>
    </item>
    <item>
      <title>Re: Turn off kernel line in proc ttest?</title>
      <link>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/414820#M21778</link>
      <description>&lt;P&gt;Rick,&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp;I finally got around to running this code and it worked like a charm (I knew it would!). I appreciate your help and I'm glad you're actively on the forums and always providing great blog posts!&lt;/P&gt;</description>
      <pubDate>Mon, 20 Nov 2017 12:58:24 GMT</pubDate>
      <guid>https://communities.sas.com/t5/Statistical-Procedures/Turn-off-kernel-line-in-proc-ttest/m-p/414820#M21778</guid>
      <dc:creator>TheShark</dc:creator>
      <dc:date>2017-11-20T12:58:24Z</dc:date>
    </item>
  </channel>
</rss>

