How to Use the SPSS Date Time Wizard

By Keith McCormick, Jesus Salcedo, Aaron Poh

If you have dates that have been properly declared in SPSS Statistics, you can easily do numerous types of calculations with the data. Just follow these steps:

  1. Open the nenana2.sav dataset.

    This dataset is similar to the nenana.sav dataset except that a date time stamp has been created using the original variable.

  2. Choose Transform→Date and Time Wizard.

    The window shown here appears.

    The Date and Time Wizard.

    The Date and Time Wizard.
  3. Select the Extract a Part of a Date or Time Variable radio button, and click Continue.

  4. Choose DateTime as the Date or Time variable and Day of Week as the Unit to Extract, and click Continue.

    Extracting Day of Week.

    Extracting Day of Week.
  5. Call the Result Variable the new name Day_of_Week2, and click Done.

    You can check your work against the figure in Step 11, if you like, but go ahead and do a second calculation now.

  6. Return to Transform→Date and Time Wizard.

  7. Select the Calculate with Dates and Times radio button this time, and click Continue.

  8. Choose Current Date and Time [$TIME] as Date1 and DateTime as the Date2.

  9. Select the Retain Fractional Part radio button, and click Continue.

  10. Call the Result Variable the new name Years_Since2, and click Finish.

    The selections are shown here.

    Date ­subtraction.

    Date ­subtraction.
  11. Check your work against this image.

    Dataset with calculations added.

    Dataset with calculations added.