我似乎无法使用SavReader在SPSS中阅读?将numpy.dtype更改为“ str”的想法可以避免此问题。我不太确定发生了什么事!
np.dtype = str
# Read in SPSS Database
with sRW.SavReaderNp('C:/Users/Sam/Downloads/Data.sav') as reader:
record = reader.all()
Error: "ValueError: format number 1 of "b"{'names': ['Name', 'DOB', 'SEX']} is not recognized