Working with Wide Data format

Moderators: statman, Analyst Techy, andris, Fierce, GerineL, Smash

Posts: 9
Joined: Thu Jul 09, 2015 7:01 am

Working with Wide Data format

Postby student74 » Mon Nov 23, 2015 3:31 am

Hi All,

I hope someone can help me out with a wide data question. I have restructured a long data set to a wide one so that I can see the number of times an individual has accessed different services over a 3 year period. I am trying to discern how many different services individuals are accessing over time. For example:
ID 1st Contact 2nd Contact 3rd Contact
1 1 1 1
2 1 5 3
3 2 2 1

Here, the 1st individual has only accessed the one service (given the number 1) but has done so 3 times, the 2nd individual has accessed 3 separate services and the 3rd individual has accessed 2 services. I would like to get SPSS to work this out for me so I don't have to manually count and enter the answers. This is way beyond my knowledge of SPSS. Can anyone tell if it can be done and how? (sorry for the messy table, I am not sure how to line things up in the posts).

Posts: 1477
Joined: Tue Jun 10, 2008 4:50 pm

Re: Working with Wide Data format

Postby GerineL » Mon Nov 23, 2015 2:50 pm

if you have a given number of services (say they are called 1, 2, 3, 4, 5), you can just use a count function.

Otherwise you can maybe construct a loop.

Who is online

Users browsing this forum: No registered users and 3 guests