Reputation: 4099
I'm importing a very large dataset into SPSS. Many fields in the dataset contain a "999" value, indicating a missing value. I want to instruct SPSS to view them as such. However, default each variable in SPSS is set to having "no missing values". In variable view, you have to define "999" as being the "discrete missing value" for each variable. With hundreds of variables though, this is a lot of work:
Therefore: is there a way to define "discrete missing value 999" as the default missing value for each variable on import? This would save me a lot of work, but I cannot find the answer online (I only get tutorials as to how define 999 as the missing value for each variable seperately, as I am doing now).
Your help is be greatly appreciated!
Edit Now that I think about it: I can easily replace each "999" in the dataset by an empty cell. Aren't empty cells considered missing values by SPSS?
Upvotes: 2
Views: 27999
Reputation: 5417
Syntax is your friend here as pointed out for the MISSING VALUES command. But you may have other metadata that is the same for many variables such as value labels or the measurement level. You can set those in syntax for multiple commands, but you might want to investigate the APPLY DICTIONARY command (Data > Copy Data Properties in the menus). Using it you can set up one variable with all the metadata to be shared and then apply all those specifications to a bunch of other variables.
Upvotes: 2
Reputation: 444
I think you can change it for on variable, than copy that cell, select all other cells in the missing column (in variable view) and paste to all the other cells in once.
(The ctrl-C, ctrl-V shortcuts might not work)
But yes, empty cells are read as missing too.
Upvotes: 0