1. ua 命令
適用於 stata15 用戶。可以一次性對當前工作路徑以及所有子文件夾中的文件進行轉碼(unicode),以保證中文字符可以正常顯示。
安裝
下載 ua.ado
和 ua.hlp
,放置於 D:\stata15\ado\base\u
或 D:\stata15\ado\plus\u
文件夾中。
使用
- 在 Stata 命令窗口中輸入
help ua
,查看命令介紹和 Stata 范例。參照范例使用即可。
Stata 范例
* Change current working directory (CWD) . cd D:\stata15\ado\personal\mypaper * Unicode all .dta files in CWD and files in sub-directories . ua: unicode encoding set gb18030 . ua: unicode translate *.dta * Unicode all files (.do, .ado, .dta, .hlp, etc.) in CWD and files in sub-directories . ua: unicode encoding set gb18030 . ua: unicode translate *
2. uall
命令
Description
uall
is shortcut for help ua
.
It executes the following two commands:
. ua: unicode encoding set gb18030
. ua: unicode translate *
Syntax
- Short version (Chinese only):
. uall
- Full version:
. uall [encoding-name]
- encoding-name is the name of encoding, see the list of encodings.
- The default is gb18030 for Chinese. So, for Chinese user, you need not specify this option.
Examples
* Change current working directory (CWD)
. cd D:\stata15\ado\personal\mypaper * For Chinese users: . uall * For Japnese users: . uall ibm-943_P15A-2003 * For Korean users: . uall ibm-970_P110_P110-2006_U2
Author
- Yujun,Lian (Arlion) Department of Finance, Lingnan College, Sun Yat-Sen University.
- E-mail: arlionn@163.com.
- 連玉君 (知乎 | 簡書 | 碼雲)