MSimulate Command

CLT is a powerful property* Stata has a wonderfully effective simulate function that allows users to easily simulate data and analysis in a very rapid fashion.* The only drawback is that when you run it, it will replace the data in memory with the simu…

Continue reading MSimulate Command

Non-Parametric PDF Fit Test

* This is an idea that I decided to explore before inspecting how others have addressed the problem.* As noted by my previous post we cannot use standard independence based draw reasoning in order to test model fit.* The following command wil…

Continue reading Non-Parametric PDF Fit Test

Macro Parsing

Do file* In Stata when programming commands we often want to be able to be able to develop our own syntax for our own commands.* The command “syntax” is often at providing a method for parsing command inputs into easily managed forms.* However, sometim…

Continue reading Macro Parsing

Return Text

do file* The following program will create a tiny program that will send to the display input text.cap program drop rtprogram define rt    local caller : di _caller()    * This will parse the `0′ text so that there is a before the c…

Continue reading Return Text

Stata Syntax Command’s Syntax

do file* When programming Stata “programs” (loosely known as functions in R) it is often times very useful to use the “syntax” command to parse arguments.* This command takes the arguments input into the command and uses them to control the function of…

Continue reading Stata Syntax Command’s Syntax