LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous messageNext messagePrevious in topicNext in topicPrevious by same authorNext by same authorPrevious page (May 2011, week 5)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:   Tue, 31 May 2011 16:23:45 +0200
Reply-To:   Tom Cohen <cohen.tom78@GMAIL.COM>
Sender:   "SAS(r) Discussion" <SAS-L@LISTSERV.UGA.EDU>
From:   Tom Cohen <cohen.tom78@GMAIL.COM>
Subject:   Display percentage within subgroup using hbar in proc gchart
Content-Type:   text/plain; charset=windows-1252

Dear list,

I have 3 questions (F16), each split into 4 different groups , each answering 'sometime' or 'often' or ‘never’ and ‘don’t know’. The following codes

give me the exact barchart I want except that I would like the percentage of each answer within each group for each question to be displayed on the barchart and the total percentage of the answers within group for each question has to be added to 100. Using G100 only gives the total percentage within group but not within subgroup. I could do separate barchart for each question but I prefer to have them all in one graph.

*proc* *gchart* data=Workdata.seb;

hbar Q35 / GROUP=F16 subgroup=Q16 discrete

type=percent freq G100

INSIDE=PCT

descending noframe maxis=axis1 raxis=axis2;

where Q16 ne *.*;

*run*;

*quit*;

Any help would be appreciated.

Best regards

Tom


Back to: Top of message | Previous page | Main SAS-L page