Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

RE: st: svmat to different datasheet

From   "Nick Winter" <>
To   <>
Subject   RE: st: svmat to different datasheet
Date   Thu, 12 Sep 2002 11:24:26 -0400

> -----Original Message-----
> From: Christa Scholtz [mailto:cscholtz@Princeton.EDU] 
> Sent: Thursday, September 12, 2002 11:07 AM
> To:
> Subject: Re: st: svmat to different datasheet
> Hi,
> I'd be very interested to know how to transform a matrix into 
> a dataset
> within stata.  I couldn't figure out how, so I found a home-cooked
> solution (feasible only if you have a handful of matrices) which
> basically bypasses stata.
> I  list the matrix in a log file.  Then, I open the log file in word,
> erase all text except the matrix, and save this as a txt file.  I then
> open the txt file in Excel, which will recognize the text file is in
> columns, and then I have a spreadsheet of my matrix data.  I 
> save it as
> a tab delimited txt file, then insheet it back into stata.  
> If you find
> a way to feed the log file directly into excel, let me know.
> once you have a number of excel worksheets, you can merge them into
> stata and create a big dataset.
> Not fancy, but it works.
> Christa

You should be able to:

	. preserve
	. drop _all
	. svmat <matname>
	. save <filename>
	. restore

--Nick Winter
*   For searches and help try:

© Copyright 1996–2015 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index