BookmarkSubscribeRSS Feed
RitCF
Calcite | Level 5

Hi!

I am trying to do ANOVA analysis with Duncan grouping. However, the results window is showing only the colour code instead of a letter code. How can I convert results into a letter code? Thanks in advance!

 

 

Result_with colour codeResult_with colour codeResult_with letter codeResult_with letter code

 

 

 

9 REPLIES 9
ballardw
Super User

As a minimum you should share the code you are using, or the code generate by choices.

There are at least half a dozen procs that do ANOVA in some form and display choices vary by Procedure.

Also you may need to share some example data to use for testing.

 

Is the table on the left what you actually want? I'm not quite sure I understand exactly what you expect for result.

RitCF
Calcite | Level 5
Hi!
Yes, I want the result in a tabular format that appears in a letter coding (like A, AB, BC, C etc..) instead of colour coding. Please find the data set and code below that I am using.

title1 'Nitrogen Content of Red Clover Plants';
data Clover;
input Strain $ Nitrogen @@;
datalines;
3DOK1 19.4 3DOK1 32.6 3DOK1 27.0 3DOK1 32.1 3DOK1 33.0
3DOK5 17.7 3DOK5 24.8 3DOK5 27.9 3DOK5 25.2 3DOK5 24.3
3DOK4 17.0 3DOK4 19.4 3DOK4 9.1 3DOK4 11.9 3DOK4 15.8
3DOK7 20.7 3DOK7 21.0 3DOK7 20.5 3DOK7 18.8 3DOK7 18.6
3DOK13 14.3 3DOK13 14.4 3DOK13 11.8 3DOK13 11.6 3DOK13 14.2
COMPOS 17.3 COMPOS 19.4 COMPOS 19.1 COMPOS 16.9 COMPOS 20.8
;
proc anova data=Clover;
class Strain;
model Nitrogen = Strain;
means Strain / duncan waller;
run;

I found this code from the SAS/STAT(R) 9.2 User's Guide, Second Edition. I want the result as it has been shown in this guide.


Thanks!
PGStats
Opal | Level 21

Use the LINESTABLE option. To get datasets, request

 

ODS OUTPUT MCLines=MCLines MCLinesInfo=MCLinesInfo MCLinesRange=MCLinesRange;

PG
Serko
Calcite | Level 5

How to add linetable option? 

Chamini
Calcite | Level 5

I tried this code as follows
title1 'AUDPC values of pepper plants';
data Pepper;
input Sample $ AUDPC @@;
datalines;
MB1 04.19 MB1 02.09
MB2 10.67 MB2 10.57
MB3 07.75 MB3 07.94
MB4 14.71 MB4 12.00
MB5 15.14 MB5 12.43
MB6 16.91 MB6 12.55
MB7 18.00 MB7 18.00
MB8 17.56 MB8 16.91
MB9 12.71 MB9 15.52
MB10 18.00 MB10 18.13
;
proc anova data=Pepper;
class Sample;
model AUDPC = Sample;
means Sample / duncan waller;
ODS OUTPUT MCLines=MCLines MCLinesInfo=MCLinesInfo MCLinesRange=MCLinesRange;
run;
It did not work

 

Serko
Calcite | Level 5

hello! Did you convert your results into letter?

Chamini
Calcite | Level 5

I would also like to have the code to convert results in to letter

Rick_SAS
SAS Super FREQ

To get the table instead of the graph, use
ODS GRAPHICS OFF;

as explained in this article: Introducing the new SAS/STAT lines plot - Graphically Speaking

For an overview of the LINESPLOT, its advantages, and its limitations, see Graphs for multiple comparisons of means: The lines plot - The DO Loop (sas.com) 

ashrafali
Calcite | Level 5

from code remove     ODS GRAPHICS ON;     and   ODS GRAPHICS OFF;

 

sas-innovate-2024.png

Available on demand!

Missed SAS Innovate Las Vegas? Watch all the action for free! View the keynotes, general sessions and 22 breakouts on demand.

 

Register now!

How to Concatenate Values

Learn how use the CAT functions in SAS to join values from multiple variables into a single value.

Find more tutorials on the SAS Users YouTube channel.

Click image to register for webinarClick image to register for webinar

Classroom Training Available!

Select SAS Training centers are offering in-person courses. View upcoming courses for:

View all other training opportunities.

Discussion stats
  • 9 replies
  • 5255 views
  • 0 likes
  • 7 in conversation