Statalist


[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: drop if


From   Ana Gabriela Guerrero Serdan <ag_guerreroserdan@yahoo.com>
To   statalist@hsphsun2.harvard.edu
Subject   st: drop if
Date   Fri, 21 Dec 2007 10:32:01 -0800 (PST)

Dear all, 

Im using drop if to drop several observations, about a
100. I try using the following but receive an error
message: 

. drop if Incident=="x132a" |     Incident=="x355a" |
Incident=="x132b" |Incident=="x354a" |
Incident=="x353a" | Incident=="x353b" | 
Incident=="x355b" | 
invalid syntax
r(198);

but when I drop one by one it works: 


. drop if Incident=="x132a"
(41 observations deleted)


. drop if  Incident=="x355a" 
(26 observations deleted)


Anyone knows why  I cannot use "|" in this case? 

thanks, 
Gaby 



Gaby Guerrero Serdan 

Deparment of Economics
Royal Holloway, University of London
TW20 OEX
Egham, Surrey
England, UK
http://www.rhul.ac.uk/economics/About-Us/postgrads.html
http://www.flickr.com/photos/49939890@N00/

Tel: +44 7912657259


      ____________________________________________________________________________________
Looking for last minute shopping deals?  
Find them fast with Yahoo! Search.  http://tools.search.yahoo.com/newsearch/category.php?category=shopping
*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



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