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 (October 2006)Back to main SPSSX-L pageJoin or leave SPSSX-L (or change settings)ReplyPost a new messageSearchProportional fontNon-proportional font
Date:         Fri, 27 Oct 2006 10:41:37 -0700
Reply-To:     Nico Peruzzi <nperuzzi@gmail.com>
Sender:       "SPSSX(r) Discussion" <SPSSX-L@LISTSERV.UGA.EDU>
From:         Nico Peruzzi <nperuzzi@gmail.com>
Subject:      Re: recode DD-MMM-YY to MMM-YY
Comments: To: "Oliver, Richard" <roliver@spss.com>
In-Reply-To:  <E0428445172CB7469BF187FF4D005149041E1727@CHIEMAIL1.spss.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed

Thanks - just what I needed.

Nico

On 10/27/06, Oliver, Richard <roliver@spss.com> wrote: > > data list free /datevar (date11). > begin data > 28-OCT-2006 > end data. > *same internal value, different display format. > compute newdate1=datevar. > formats newdate1 (moyr9). > *internally, the first day of the month. > compute newdate2=date.moyr(xdate.month(datevar), xdate.year(datevar)). > formats newdate2(moyr9). > > > -----Original Message----- > From: SPSSX(r) Discussion [mailto:SPSSX-L@LISTSERV.UGA.EDU] On Behalf Of > Nico Peruzzi > Sent: Friday, October 27, 2006 11:36 AM > To: SPSSX-L@LISTSERV.UGA.EDU > Subject: recode DD-MMM-YY to MMM-YY > > I have a date variable in the format DD-MMM-YY and I want to ignore the > day and recode it to MMM-YY. > > For example, both 12-JAN-2006 and 30-JAN-2006 would be recoded into > JAN-2006 (or 01-JAN-2006 would be fine too). > > Xdate.Month isn't quite right. It's as though I need something like > Xdate.MonthYear. > > Thanks in advance for any tips, Nico > > -- > Nico Peruzzi, Ph.D. >

-- Nico Peruzzi, Ph.D.


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