Merging a file in SPSS (from many to few cases)

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

tomcooper
Posts: 2
Joined: Thu Feb 13, 2014 6:53 pm

Merging a file in SPSS (from many to few cases)

Postby tomcooper » Thu Feb 13, 2014 7:00 pm

Hi Everybody!

I have a pressing question:

let's say I have an amount of respondents (1000) with unique ID codes in small dataset A.
I want to merge variables at hand of these ID codes from dataset B. IN this dataset, there are approximately 50.000.000 cases (1000 of these ID's are equal to the respondents in dataset A).

How can I merge the relevant variables to the 1000 individuals without getting all the 50.000.000 cases?

It would be awesome if somebody could help me out!

Kind regards,
Tom
GerineL
Moderator
Posts: 1477
Joined: Tue Jun 10, 2008 4:50 pm

Re: Merging a file in SPSS (from many to few cases)

Postby GerineL » Fri Feb 14, 2014 9:06 am

start merging from the first file with 1000 cases, click second option in keyed table part under menu.
tomcooper
Posts: 2
Joined: Thu Feb 13, 2014 6:53 pm

Re: Merging a file in SPSS (from many to few cases)

Postby tomcooper » Fri Feb 14, 2014 11:18 am

Hi Gutnre,

I think i see what is wrong: the big set contains more cases (e.g. where the small set contains one ID no 667, the large set may contain 5 ID's with the number 667). Is there a way to select only the ID numbers of the small set from the large set?

Kind regards,
Tom
GerineL
Moderator
Posts: 1477
Joined: Tue Jun 10, 2008 4:50 pm

Re: Merging a file in SPSS (from many to few cases)

Postby GerineL » Fri Feb 14, 2014 1:27 pm

this way spss doesn't know which of the 4 667's you want to take the data from.
so ID's on which you match should be unique.

if they are actually identical (i.e., 4x the same data), you could use the identify duplicate cases procedure in the large dataset in order to find (and then delete) duplicates.

if not, you have to figure out how spss should decide which of these cases it should copy.

Who is online

Users browsing this forum: No registered users and 2 guests

cron