A problem with SPSS is that it does not readily calculate the higher level residuals - there is syntax for it however in the SPSS review on the Centre for Multilevel Modelling software reviews by Alistair Leyland
see SPSS review - University of Bristolhttp://www.bristol.ac.uk/cmm/learning/mmsoftware/spss.html
This book is a pretty comprehensive guide to the recently added capabilities but I found no discussion of the residuals
Multilevel Modeling of Categorical Outcomes Using IBM SPSS
By Ronald H Heck, Scott Thomas, Lynn Tabata
In terms of R you may be interested in R2mlwin which allows you to access mlwin through R
If you are looking purely to extract the residuals of both linear and generalized linear mixed models fit with lme4, you can use the residuals.merMod() function in the lme4 library. Residual standard errors can also be accessed with sigma() also in the lme4 library but this only supports merMod class objects and not glmerMod.
I also believe that resid() can handle merMod and glmerMod objects. So a command like: