Hi Shantanu,
It sounds like you want to use 3dmaskave. If you run it with the
-mask option to supply your ROI, and possibly -mrange, to supply
lower and upper limits for ROI values (if you have multiple ROIs to
choose from), then you can redirect the output to a text file.
For instance, consider:
3dmaskave -mask ROI+orig -mrange 3 3 -quiet run01+orig > ROI_3_ts.txt
That would create ROI_3_ts.txt, a text file containing the average
timeseries in run01+orig, restricted to voxels where ROI+orig has a
value of 3.
- rick