Surely, instead of typing
global D wordcount($demographe) ;
you should type
global D: word count $demographe ;
See the online help by typing
help extended_fcn
in Stata.
I hope this helps.
Roger
--
Roger Newson
Lecturer in Medical Statistics
Department of Public Health Sciences
Division of Asthma, Allergy and Lung Biology
King's College London
5th Floor, Capital House
42 Weston Street
London SE1 3QD
United Kingdom
Tel: 020 7848 6648 International +44 20 7848 6648
Fax: 020 7848 6620 International +44 20 7848 6620
or 020 7848 6605 International +44 20 7848 6605
Email: [email protected]
Website: http://phs.kcl.ac.uk/rogernewson/
Opinions expressed are those of the author, not the institution.
Svend Juul wrote:
I have a problem with the syntaxe global
When I type
global demographe "one NE SOUTH MIDWEST sex_c age_c kids05
kids610 kids1115 voiture maison" ;
then
global D wordcount($demographe) ;
I expect that stata returns the number 11
but I get the folowing message when I type
dis $D
oneNESOUTHMIDWESTsex_cage_ckids05kids610kids1115voituremaison
invalid name
----------------------------------------------------------
Abdelrahmen,
It is:
global D wordcount("$demographe")
Svend
__________________________________________
Svend Juul
Institut for Folkesundhed, Afdeling for Epidemiologi
(Institute of Public Health, Department of Epidemiology)
Vennelyst Boulevard 6
DK-8000 Aarhus C, Denmark
Phone: +45 8942 6090
Home: +45 8693 7796
Email: [email protected]
__________________________________________
*
* 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/
*
* 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/