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 (September 1998, week 4)Back to main SAS-L pageJoin or leave SAS-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Fri, 25 Sep 1998 13:39:44 -0400
Reply-To:     RHOADSM1 <RHOADSM1@WESTAT.COM>
Sender:       "SAS(r) Discussion" <SAS-L@UGA.CC.UGA.EDU>
From:         RHOADSM1 <RHOADSM1@WESTAT.COM>
Subject:      Re: Tabulate var is character
Comments: To: "Boylan; Dave" <dboylan@UTILICORP.COM>
Content-Type: text/plain; charset=US-ASCII

Dave,

As I understand your problem, CUST contains a count of customers for each record, and you want to use it as what TABULATE would call an "analysis" variable, despite the fact that it is currently character. If that's the case, I think you're stuck, in the sense that analysis variables must be numeric (which is logical). You could either make CUST numeric or create a new variable and use that, either by creating a new data set or possibly by using a DATA step or SQL view.

Mike Rhoads Westat RhoadsM1@Westat.com

<<original question>> I'm trying to summarize a data set using Tabulate. I'm running into trouble because my 'cust' variable is character. I want to count the number of customers by state and year. The error is:

'ERROR: Variable CUST in list does not match type prescribed for this list.'

Is there a simple way to get the job done, other than a data step to change the cust var from character to numeric?

The code is:

Proc tabulate missing data=folder.png; where yrmo ge 9605 and yrmo le 9607; class yrmo state; var cust; Table state, yrmo*cust*f=comma12.; run;

Thanks -------------------------------------- David Boylan Corporate Forecasting UtiliCorp United, Inc. 816.467.3062 --------------------------------------


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