
-
Login or Register
- Log in with
mi impute chained ... (mlogit, skipnonconvergence(#)) ...
scalar S2 = ustrregexra(S1,"[^\p{L}\p{M}\p{N}\p{P}\p{S}\p{Zs}]","")
scalar S2 = itrim(ustrregexra(S2,"\p{Zs}",ustrunescape("\u0020")))
\p{L} or \p{Letter}: any kind of letter from any language \p{M} or \p{Mark} : a character intended to be combined with another character \p{N} or \p{Number}: any kind of numeric character in any script. \p{P} or \p{Punctuation}: any kind of punctuation character. \p{S} or \p{Symbol}: math symbols, currency signs, dingbats, box-drawing characters, etc. \p{Zs} or \p{Space_Separator}: a whitespace character that is invisible, but does take up space.
. set cformat . reg y x Source | SS df MS Number of obs = 1,000 -------------+---------------------------------- F(1, 998) = 288.46 Model | 437.799556 1 437.799556 Prob > F = 0.0000 Residual | 1514.6571 998 1.51769249 R-squared = 0.2242 -------------+---------------------------------- Adj R-squared = 0.2235 Total | 1952.45666 999 1.95441107 Root MSE = 1.2319 ------------------------------------------------------------------------------ y | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- x | .4625608 .0272347 16.98 0.00 .4091169 .5160047 _cons | .0619798 .0389869 1.59 0.11 -.0145258 .1384855 ------------------------------------------------------------------------------ . corr y x (obs=1,000) | y x -------------+------------------ y | 1.0000 x | 0.4735 1.0000 . set cformat %5.2f . reg y x Source | SS df MS Number of obs = 1,000 -------------+---------------------------------- F(1, 998) = 288.46 Model | 437.799556 1 437.799556 Prob > F = 0.0000 Residual | 1514.6571 998 1.51769249 R-squared = 0.2242 -------------+---------------------------------- Adj R-squared = 0.2235 Total | 1952.45666 999 1.95441107 Root MSE = 1.2319 ------------------------------------------------------------------------------ y | Coef. Std. Err. t P>|t| [95% Conf. Interval] -------------+---------------------------------------------------------------- x | 0.46 0.03 16.98 0.00 0.41 0.52 _cons | 0.06 0.04 1.59 0.11 -0.01 0.14 ------------------------------------------------------------------------------ . corr y x (obs=1,000) | y x -------------+------------------ y | 1.0000 x | 0.4735 1.0000
Leave a comment: