LISTSERV at the University of Georgia
Menubar Imagemap
Home Browse Manage Request Manuals Register
Previous (more recent) messageNext (less recent) messagePrevious (more recent) in topicNext (less recent) in topicPrevious (more recent) by same authorNext (less recent) by same authorPrevious page (July 2008)Back to main SPSSX-L pageJoin or leave SPSSX-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Thu, 10 Jul 2008 00:16:18 -0400
Reply-To:     Richard Ristow <wrristow@mindspring.com>
Sender:       "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From:         Richard Ristow <wrristow@mindspring.com>
Subject:      Re: Remove ID's with missing month end data
Comments: To: jimjohn <azam.khan@utoronto.ca>
Comments: cc: Gene Maguin <emaguin@buffalo.edu>,
          ViAnn Beadle <vab88011@gmail.com>
In-Reply-To:  <18369687.post@talk.nabble.com>
Content-Type: text/plain; charset="us-ascii"; format=flowed

Oh, dear.

At 04:08 PM 7/9/2008, jimjohn wrote:

>ok i just tried "compute laggegd = lag(ID). and here is the error I got: > >compute lagged = LAG(ID). > >>Error # 4309 in column 1024. Text: (End of Command) >>Invalid combination of data types in an assignment.

Right. And back Wed, 9 Jul 2008 (10:55:10 -0700) you asked, "Is there any way to lag a string variable?", i.e. your ID.

And yes, Lag works fine with string variables. I think both Gene and ViAnn Beadle have told you that.

The problem is that variable 'lagged' is *NOT* a string variable; so, you get the "Invalid combination of data types." A new variable is a string variable only if it's declared on a "STRING" statement.

I don't see your stating how long 'ID' is. If it's 11 characters, this will work:

STRING lagged(A11). compute lagged = LAG(ID).

And none of this has anything to do with file size.

===================== To manage your subscription to SPSSX-L, send a message to LISTSERV@LISTSERV.UGA.EDU (not to SPSSX-L), with no body text except the command. To leave the list, send the command SIGNOFF SPSSX-L For a list of commands to manage subscriptions, send the command INFO REFCARD


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