Nuno,
What you could do is to produce an alternative date variable which
contains the "elapsed work days". Given that your original date
variable (in Stata's date format) is called "date", then you can
generate the respective variable as follows:
gen wdate = floor((date-1)/7)*5+dow(date)
Unfortunately, however, I have no idea on how to label this variable
such that it shows the date in a %d format...
But now you can -tsset- your dataset with
tsset id wdate
and compute the returns by aid of the lag-operator. However, note that
variable wdate does not know any holidays and non-trading days.
Therefore, whenever there is a non-trading day on a weekday, there
will be a missing return for this specific return.
I hope this helps.
Best,
Daniel
*
* 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/