Template-Type: ReDIF-Article 1.0 Author-Name: David Benson Author-Workplace-Name: Federal Reserve Board of Governors Author-Email: david.a.benson@frb.gov Author-Person: pbe1232 Author-Name: Matthew A. Masten Author-Workplace-Name: Duke University Author-Email: matt.masten@duke.edu Author-Person: pma2923 Author-Name: Alexander Torgovitsky Author-Workplace-Name: University of Chicago Author-Email: torgovitsky@uchicago.edu Author-Person: pto480 Title: ivcrc: An instrumental-variables estimator for the correlated random-coefficients model Journal: Stata Journal Pages: 469-495 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: We discuss the ivcrc command, which implements an instrumental- variables (IV) estimator for the linear correlated random-coefficients model. The correlated random-coefficients model is a natural generalization of the standard lin- ear IV model that allows for endogenous, multivalued treatments and unobserved heterogeneity in treatment effects. The estimator implemented by ivcrc uses re- cent semiparametric identification results that allow for flexible functional forms and permit instruments that may be binary, discrete, or continuous. The ivcrc command also allows for the estimation of varying-coefficient regressions, which are closely related in structure to the proposed IV estimator. We illustrate the use of ivcrc by estimating the returns to education in the National Longitudinal Survey of Young Men. Keywords: ivcrc, ivregress, instrumental variables, correlated random co- efficients, heterogeneous treatment effects, varying-coefficient models, returns to schooling File-URL: http://www.stata-journal.com/article.html?article=st0680 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124449 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0646/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:469-495 Template-Type: ReDIF-Article 1.0 Author-Name: Sven-Kristjan Bormann Author-Workplace-Name: University of Tartu Author-Email: sven-kristjan@gmx.de Title: A Stata implementation of second-generation p-values Journal: Stata Journal Pages: 496-520 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: In this article, I introduce new commands to calculate second-generation p-values (SGPVs) for common estimation commands in Stata. The sgpv command and its companions allow the easy calculation of SGPVs and their asso- ciated diagnostics, as well as the plotting of SGPVs against the standard p-values. Keywords: sgpv, fdrisk, plotsgpv, sgpower, sgpvalue, second-generation p-values File-URL: http://www.stata-journal.com/article.html?article=st0681 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124466 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0647/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:496-520 Template-Type: ReDIF-Article 1.0 Author-Name: Daniel Guinea-Martin Author-Workplace-Name: Universidad de Málaga Author-Email: daniel.guinea@uma.es Author-Person: Author-Name: Ricardo Mora Author-Workplace-Name: Universidad Carlos III de Madrid Author-Email: ricmora@eco.uc3m.es Title: Computing decomposable multigroup indices of segregation Journal: Stata Journal Pages: 521-556 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: Eight multigroup segregation indices are decomposable into a between and a within term. They are two versions of 1) the mutual information index, 2) the symmetric Atkinson index, 3) the relative diversity index, and 4) Theil’s H index. In this article, we present the command dseg, which obtains all of them. It contributes to the stock of segregation commands in Stata by 1) implement- ing the decomposition in a single call, 2) providing the weights and local indices used in the computation of the within term, 3) facilitating the deployment of the decomposability properties of the eight indices in complex scenarios that demand tailor-made solutions, and 4) leveraging sample data with bootstrapping and ap- proximate randomization tests. We analyze 2017 census data of public schools in the United States to illustrate the use of dseg. The subject topic is school racial segregation. Keywords: dseg, Atkinson, decomposability, multigroup, mutual informa- tion, race, relative diversity, Theil’s H, schools, segregation File-URL: http://www.stata-journal.com/article.html?article=st0682 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124471 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0648/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:521-566 Template-Type: ReDIF-Article 1.0 Author-Name: Jochem Huismans Author-Workplace-Name: University of Amsterdam Author-Email: jochemhuismans@gmail.com Author-Name: Jan Willem Nijenhuis Author-Workplace-Name: Nedap NV Author-Email: janwillemnijenhuis@gmail.com Author-Name: Andrei Sirchenko Author-Workplace-Name: Nyenrode Business University Author-Email: andrei.sirchenko@gmail.com Author-Person: psi424 Title: A mixture of ordered probit models with endogenous switching between two latent classes Journal: Stata Journal Pages: 557-596 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: Ordinal responses can be generated, in a cross-sectional context, by different unobserved classes of population or, in a time-series context, by differ- ent latent regimes. We introduce a new command, swopit, that fits a mixture of ordered probit models with exogenous or endogenous switching between two latent classes (regimes). Switching is endogenous if unobservables in the class- assignment model are correlated with unobservables in the outcome models. We provide a battery of postestimation commands; assess via Monte Carlo experiments the finite-sample performance of the maximum likelihood estimator of the param- eters, probabilities, and their standard errors (both the asymptotic and bootstrap ones); and apply the new command to model the monetary policy interest rates. Keywords: swopit, swopit postestimation, swopitpredict, swopitprobabilities, swopitmargins, swopitclassification, ordinal responses, ordered probit, finite mixture model, latent class, regime switching, endogenous switching File-URL: http://www.stata-journal.com/article.html?article=st0683 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124516 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0649/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:557-596 Template-Type: ReDIF-Article 1.0 Author-Name: Marinho Bertanha Author-Workplace-Name: University of Notre Dame Author-Email: mbertanha@nd.edu Author-Person: pbe1000 Author-Name: Andrew H. McCallum Author-Workplace-Name: Board of Governors of the Federal Reserve System Author-Email: andrew.h.mccallum@frb.gov Author-Person: pmc122 Author-Name: Alexis Payne Author-Workplace-Name: Stanford University Author-Email: ampayne@stanford.edu Author-Name: Nathan Seegert Author-Workplace-Name: University of Utah Author-Email: nathan.seegert@eccles.utah.edu Author-Person: pse700 Title: Bunching estimation of elasticities using Stata Journal: Stata Journal Pages: 597-624 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: Typical censoring models have mass points at the upper or lower tails, or at both tails, of an otherwise continuous outcome distribution. In contrast, we consider a censoring model with a mass point in the interior of the outcome dis- tribution. We refer to this mass point as “bunching” and use it to estimate model parameters. For example, economic theory suggests that, for increasing marginal income tax rates, many taxpayers will report income exactly at the threshold where the tax rate increases. This translates into a censoring model with bunching at the threshold. The size of this mass point of taxpayers can be used to estimate an elasticity parameter that summarizes taxpayers’ responses to taxes. In this article, we introduce the command bunching, which implements new nonparamet- ric and semiparametric identification methods for estimating elasticities developed by Bertanha, McCallum, and Seegert (2021, Technical Report 2021-002, Board of Governors of the Federal Reserve System). These methods rely on weaker assump- tions than what are currently made in the literature and result in meaningfully different estimates of the elasticity. Keywords: bunching, bunchbounds, bunchtobit, bunchfilter, midcensoring, partial identification, censored regression, income elasticity, tax File-URL: http://www.stata-journal.com/article.html?article=st0684 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124534 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0650/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:597-624 Template-Type: ReDIF-Article 1.0 Author-Name: Aramayis Dallakyan Author-Workplace-Name: StataCorp Author-Email: adallakyan@stata.com Title: graphiclasso: Graphical lasso for learning sparse inverse-covariance matrices Journal: Stata Journal Pages: 625-642 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: In modern multivariate statistics, where high-dimensional datasets are ubiquitous, learning large (inverse-) covariance matrices is imperative for data analysis. A popular approach to estimating a large inverse-covariance matrix is to regularize the Gaussian log-likelihood function by imposing a convex penalty function. In a seminal article, Friedman, Hastie, and Tibshirani (2008, Biostatis- tics 9: 432–441) proposed a graphical lasso (Glasso) algorithm to efficiently esti- mate sparse inverse-covariance matrices from the convex regularized log-likelihood function. In this article, I first explore the Glasso algorithm and then introduce a new graphiclasso command for the large inverse-covariance matrix estima- tion. Moreover, I provide a useful command for tuning parameter selection in the Glasso algorithm using the extended Bayesian information criterion, the Akaike information criterion, and cross-validation. I demonstrate the use of Glasso using simulation results and real-world data analysis. Keywords: graphiclasso, graphiclassocv, graphiclassoplot, datafromicov, compareicov, graphical lasso, graphical models, inverse-covariance matrix File-URL: http://www.stata-journal.com/article.html?article=st0685 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124538 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0651/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:625-642 Template-Type: ReDIF-Article 1.0 Author-Name: Mustafa U. Karakaplan Author-Workplace-Name: University of South Carolina Author-Email: mustafa.karakaplan@moore.sc.edu Author-Person: pka1086 Title: Panel stochastic frontier models with endogeneity Journal: Stata Journal Pages: 643-663 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: In this article, I introduce xtsfkk as a new command for fitting panel stochastic frontier models with endogeneity. The advantage of xtsfkk is that it can control for the endogenous variables in the frontier and the inefficiency term in a longitudinal setting. Hence, xtsfkk performs better than standard panel frontier estimators such as xtfrontier that overlook endogeneity by design. Moreover, xtsfkk uses Mata’s moptimize() functions for substantially faster execution and completion speeds. I also present a set of Monte Carlo simulations and examples demonstrating the performance and usage of xtsfkk. Keywords: xtsfkk, panel stochastic frontier models, longitudinal data, en- dogeneity, production frontier, cost frontier, endogenous inefficiency File-URL: http://www.stata-journal.com/article.html?article=st0686 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124539 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0652/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:643-663 Template-Type: ReDIF-Article 1.0 Author-Name: Pengyu Chen Author-Workplace-Name: University of Birmingham Author-Email: cpy1416@outlook.com Author-Name: Yiannis Karavias Author-Workplace-Name: University of Birmingham Author-Email: i.karavias@bham.ac.uk Author-Person: pka744 Author-Name: Elias Tzavalis Author-Workplace-Name: Athens University of Economics and Business Author-Email: e.tzavalis@aueb.gr Author-Person: ptz13 Title: Panel unit-root tests with structural breaks Journal: Stata Journal Pages: 664-678 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: In this article, we introduce a new community-contributed command called xtbunitroot, which implements the panel-data unit-root tests developed by Karavias and Tzavalis (2014, Computational Statistics and Data Analysis 76: 391–407). These tests allow for one or two structural breaks in deterministic components of the series and can be seen as panel-data counterparts of the tests by Zivot and Andrews (1992, Journal of Business and Economic Statistics 10: 251–270) and Lumsdaine and Papell (1997, Review of Economics and Statistics 79: 212–218). The dates of the breaks can be known or unknown. The tests allow for intercepts and linear trends, nonnormal errors, and cross-section heteroskedas- ticity and dependence. They have power against homogeneous and heterogeneous alternatives and can be applied to panels with small or large time-series dimensions. Keywords: xtbunitroot, panel data, unit root, structural break, banking, COVID-19 File-URL: http://www.stata-journal.com/article.html?article=st0687 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124541 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0653/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:664-678 Template-Type: ReDIF-Article 1.0 Author-Name: Hannah Bower Author-Workplace-Name: Department of Medicine Solna, Karolinska Institutet Author-Email: hannah.bower@ki.se Author-Name: Therese M.-L. Andersson Author-Workplace-Name: Karolinska Institutet Author-Email: therese.m-l.andersson@ki.se Author-Name: Michael J. Crowther Author-Workplace-Name: Karolinska Institutet Author-Email: michael.crowther@ki.se Author-Name: Paul C. Lambert Author-Workplace-Name: Department of Health Sciences, University of Leicester Author-Email: paul.lambert@leicester.ac.uk Title: Flexible parametric survival analysis with multiple timescales: Estimation and implementation using stmt Journal: Stata Journal Pages: 679-701 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: In this article, we describe methodology that allows for multiple timescales using flexible parametric survival models without the need for time splitting. When one fits flexible parametric survival models on the log-hazard scale, numerical integration is required in the log likelihood to fit the model. The use of numerical integration allows incorporation of arbitrary functions of time into the model and hence lends itself to the inclusion of multiple timescales in an appealing way. We describe and exemplify these methods and show how to use the command stmt, which implements these methods, alongside its postestimation commands. Keywords: stmt, stmt postestimation, flexible parametric survival model, multiple timescales File-URL: http://www.stata-journal.com/article.html?article=st0688 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124552 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0653/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:679-701 Template-Type: ReDIF-Article 1.0 Author-Name: Edward C. Norton Author-Workplace-Name: University of Michigan Author-Email: ecnorton@umich.edu Author-Person: pno89 Title: The inverse hyperbolic sine transformation and retransformed marginal effects Journal: Stata Journal Pages: 702-712 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: In this article, I show how to calculate consistent marginal effects on the original scale of the outcome variable in Stata after estimating a linear regression with a dependent variable that has been transformed by the inverse hyperbolic sine function. The method uses a nonparametric retransformation of the error term and accounts for any scaling of the dependent variable. The inverse hyperbolic sine function is not invariant to scaling, which is known to shift marginal effects between those from an untransformed dependent variable to those of a log- transformed dependent variable, when all observations are positive. Keywords: inverse hyperbolic sine, transformation, marginal effects File-URL: http://www.stata-journal.com/article.html?article=st0689 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124553 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0653/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:702-712 Template-Type: ReDIF-Article 1.0 Author-Name: Yuya Sasaki Author-Workplace-Name: Vanderbilt University Author-Email: yuya.sasaki@vanderbilt.edu Author-Person: psa1792 Author-Name: Yi Xin Author-Workplace-Name: California Institute of Technology Author-Email: yixin@caltech.edu Title: xtusreg: Software for dynamic panel regression under irregular time spacing Journal: Stata Journal Pages: 713-724 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: We introduce a new command, xtusreg, that estimates parameters of fixed-effects dynamic panel regression models under unequal time spacing. After reviewing the method, we examine the finite-sample performance of the command using simulated data. We also illustrate the command with the National Longitu- dinal Survey Original Cohorts: Older Men, whose personal interviews took place in the unequally spaced years of 1966, 1967, 1969, 1971, 1976, 1981, and 1990. The methods underlying xtusreg are those discussed by Sasaki and Xin (2017, Journal of Econometrics 196: 320–330). Keywords: xtusreg, dynamic panel regression, fixed effect, unequal time spacing File-URL: http://www.stata-journal.com/article.html?article=st0690 File-Function: link to article purchase X-DOI: 10.1177/1536867X221124567 Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0653/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:713-724 Template-Type: ReDIF-Article 1.0 Author-Name: Editors Author-Email: editors@stata.com Title: Software updates Journal: Stata Journal Pages: 725 Issue: 3 Volume: 22 Year: 2022 Month: September Abstract: Updates for previously published packages are provided. Note: to access software from within Stata, net describe http://www.stata-journal.com/software/sj22-3/st0288_1/ Handle:RePEc:tsj:stataj:y:22:y:2022:i:3:p:725