Stata:不允许使用错误因子变量和时间序列运算符

gio*_*ano 3 stata

我想将数据从Stata导出到csv文件中:

 outsheet "$dirLink/analysis.csv",  replace comma
Run Code Online (Sandbox Code Playgroud)

但是我收到以下错误消息:

 factor variables and time-series operators not allowed
 r(101);
Run Code Online (Sandbox Code Playgroud)

我无法在网上找到解决方案.感谢帮助.

以下是变量定义:

 tab0            str1   %9s                    
 linkid          float  %10.0g                 
 recid2          float  %9.0g                  
 recid1          float  %10.0g                 
 patient1        str28  %28s                   
 patient2        str9   %9s                    
 totwght         int    %10.0g                 
 status          str1   %9s                    
 fname           str13  %13s                   
 sname           str13  %13s                   
 doby            int    %10.0g                 
 cohort          str2   %9s    
 res1            str27  %27s                   
 res2            str29  %29s                   
 residence       str50  %50s   
 facility        str22  %22s                   
 maxwght         int    %10.0g  
Run Code Online (Sandbox Code Playgroud)

Nic*_*Cox 7

语法应该是

outsheet using "$dirLink/analysis.csv",  replace comma
Run Code Online (Sandbox Code Playgroud)

也就是说,这个词using是必需的.这在帮助中有记录:无需进行互联网搜索.确实错误消息不是透明的,因为Stata猜测你正在尝试除了using或者变量列表之外的其他东西,其中任何一个都可以跟随outsheet.

PS在我对你上一个问题的回答中我指出正确的拼写是Stata:请参阅http://www.stata.com/support/faqs/resources/statalist-faq/#spell这仍然是正确的.