Stata 中文字符显示成问号,该怎么解决

如题所述

第1个回答  2017-10-22
在开始用unicode之前是不能打开任何数据库的,否则Stata会提醒你data in memory would be lost 还有there must be no data in memory]
cd "D:\long term care\CHARLS\stata\data\household_and_community_questionnaire_data" 【先设置你的working directory】
unicode analyze psu.dta
(Directory ./bak.stunicode created; please do not delete)
File summary (before starting):
1 file(s) specified
1 file(s) to be examined ...
File psu.dta (Stata dataset)
2 str# variables need translation
----------------------------------------------------------------------------------------------------------
File needs translation. Use unicode translate on this file.
File psu.dta needs translation
File summary:
1 file(s) need translation
【总结:Stata告诉你,你这个file需要转换】
【这里就是让Stata把数据转换为支持中文的UTF-8,转换完毕后,检查数据,中文终于不是乱码了,大功告成!】
相似回答