Dear all

I would like to count the number of values across 5 numeric variables. I tried using "anycount", but there is a wide range of values for me to list all of them in the option statement and the syntax wont allow me to specify range:

2 syntaxes I tried below:

egen sum_xy = anycount (x y z v w), value (1,2,3,4......1000)

egen sum_xy = anycount (x y z v w), value (1-1000)