date wizard

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

date wizard

Chelminski, Iwona
Hi Group
I was wondering if you could help me again with the dates.
A group of people was given a test twice. I have two SPSS files with the same IDs and testing results (item1_1 and item1_2)  at two different times (date_1 and date_2).  I will merge the two files by ID, but in my test-retes analyses I want to inlcude only those people for whom the second tesing was done no more than one week after the first one.
The testing days were NOT consecutive days.

Any suggestions?
Thanks in advance,
Iwona

====================To manage your subscription to SPSSX-L, send a message to
[hidden email] (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
Reply | Threaded
Open this post in threaded view
|

Re: date wizard

Richard Ristow
Did this get solved, and I missed it? In case not,

At 07:43 PM 3/27/2008, Chelminski, Iwona wrote:

>A group of people was given a test twice. I have two SPSS files with
>the same IDs and testing results (item1_1 and item1_2)  at two
>different times (date_1 and date_2).  I will merge the two files by
>ID, but in my test-[results] analyses I want to include only those
>people for whom the second testing was done no more than one week
>after the first one.
>The testing days were NOT consecutive days.

If you have the files merged, and the variables as you describe them,
the difference in days between date_1 and date_2 is

CTIME.DAYS(date_2-date_1).

In recent version of SPSS (14+, I think), you can also use

DATEDIFF(date_2,date_1,"days")
or
DATEDIFF(date_2,date_1,"weeks")

=====================
To manage your subscription to SPSSX-L, send a message to
[hidden email] (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