Howard_Schreier@ITA.DOC.GOV (Howard Schreier) wrote in message news:<200402090047.i190lPI16629@listserv.cc.uga.edu>...
> This looks to me like it should have worked. There's some kind of runtime
> system error.
> What is the SAS Version number?
---- Version 9.0
> What is the host OS?
--- Windows XP Pro
> How many observations in the dataset? How many for MODELID=3?
--- # of observations = 22047, about 1043 for Modelid=3
> By the way, you are not trying to get the medians in a DATA step; the DATA
> step code ends with the RUN statement. The procedure (PROC) invocations are
> steps in their own right.
Thanks for helping :). Am just a beginner so am still groping around in a way!
> On Sun, 8 Feb 2004 12:01:31 -0800, seema <wormpai@HOTMAIL.COM> wrote:
> >I have a list of purchases where every customer purchases 1 brand on
> >one purchase occassion. So for some brands I have no price
> >information. I want to use the median price for that brand over the
> >entire time period instead of the missing values. So I am trying to
> >write a data step that will give me median prices for every model in a
> >separate file but am having some problems with the same. Am pasting my
> >code and the error message below. Any help is really really
> >data transac;
> >infile 'N:\Spring Semester\MKTG 613\SAS Assignment\transacw1.txt';
> >input #1 nweek 1-2 modelid 4-5 @8 (totalgro vehgross)(5.) @19
> >(vehpampr vehprice)(6.)
> > daystotu 32-35 age 37-39 havetrad 41 tradmake 42-43 ntransac 45
> > term 47-48 monthlyp 50-54 @55 apr 5.2 percentf 60-62
> > manureba 64-68 totaldow 69-74 residual 76-80
> > #2 tradeage 8-10 zipcode $ 12-16 ngender 19 censusb2 $ 23-37
> > @40 (latitude longitud)(10.4) targetgr $ 65 nreg 70 region $
> > #3 @8 (mod1-mod9)(8.4)
> > #4 @8 (mod10-mod15)(8.4)
> > #5 @8 (PCTASIA PCTBLK PCTBLUE PCTCOL
> > PCTHISP PCTLHS PCTOWN PCTRURAL)(8.4)
> > #6 @8 (H_MED HSE_MED)(8.2) @25 (HI_MED VALUEMED)(12.2)
> > @56 closedat mmddyy8. vin $ 64-80;
> > run;
> >proc sort data=transac;
> >by modelid;
> >proc means data=transac;
> >var vehprice manureba;
> >by modelid;
> >output out= transacmed median(vehprice)=medprice
> ><b> Problem </b> When I do this, I get the median prices for brands 1
> >and 2 (modelids 1 and 2 rather) and dont get the remaining brands from
> >3 to 15 although all the data is present in transac (checked that
> >already). The error message it gives me is as follows:
> >ERROR: Read Access Violation In Task ( MEANS )
> >Exception occurred at (66FE70BC)
> >Task Traceback
> >Address Frame (DBGHELP API Version 4.0 rev 5)
> >66FE70BC 050FF720 0001:000260BC sassfm01.dll
> >66FD97A2 050FF760 0001:000187A2 sassfm01.dll
> >66FD83A5 050FF7D8 0001:000173A5 sassfm01.dll
> >66FCBDC6 050FF878 0001:0000ADC6 sassfm01.dll
> >66FC386E 050FF89C 0001:0000286E sassfm01.dll
> >67008769 050FFF84 0001:00007769 sasmeans.dll
> >67E223EE 050FFFA0 0001:000113EE sashost.dll
> >67E26DE0 050FFFB4 0001:00015DE0 sashost.dll
> >77E7D33B 050FFFEC kernel32:RegisterWaitForInputIdle+0x43
> >NOTE: The SAS System stopped processing this step because of errors.
> >Thanks a ton in advance,