_e2r.ado
来自「是一个经济学管理应用软件 很难找的 但是经济学学生又必须用到」· ADO 代码 · 共 58 行
ADO
58 行
*! version 1.0.1 03jan2005
program _e2r, rclass
version 9
syntax [, ///
XMACros(namelist) ///
XSCAlars(namelist) ///
XMATrices(namelist) ///
ADD ///
]
// save the macros
local macros : e(macros)
local macros : list macros - xmacros
foreach name of local macros {
return local `name' `"`e(`name')'"'
}
// save the scalars
local scalars : e(scalars)
local scalars : list scalars - xscalars
foreach name of local scalars {
return scalar `name' = e(`name')
}
// save the matrices
local matrices : e(matrices)
local matrices : list matrices - xmatrices
tempname mat
foreach name of local matrices {
matrix `mat' = e(`name')
return matrix `name' `mat'
}
if "`add'" != "" {
// NOTE: do not use -return add- since it will not overwrite
// stuff already existing in r().
// save the macros
local macros : r(macros)
foreach name of local macros {
return local `name' `"`r(`name')'"'
}
// save the scalars
local scalars : r(scalars)
foreach name of local scalars {
return scalar `name' = r(`name')
}
// save the matrices
local matrices : r(matrices)
foreach name of local matrices {
matrix `mat' = r(`name')
return matrix `name' `mat'
}
}
end
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?