Abstract:
I will present a selection of user-written Mata functions that serve to streamline the process of writing other Mata functions, and I will demonstrate what makes them handy. I will present debugging/programming functions for the following: dropping and re-creating one or a few functions without clearing Mata of all other useful info; displaying the contents of a matrix in a compact and informative way; and copying private function information into the global space. I will present text-handling functions for the following: concatenating and dividing blocks of text; processing lists of file/directory paths; and converting between matrices of text and ASCII values. I will present more general-purpose functions for the following: combining matrices of different sizes; reading and writing Mata matrices to spreadsheet files; generating a map of matching values in two matrices; and returning an entire (small) matrix of values to Stata locals. I will finish with a combined Stata/Mata command for storing Stata command preferences.
More papers in Fall North American Stata Users' Group Meetings 2008 from Stata Users Group Contact information at EDIRC. Series data maintained by Christopher F Baum ().