I'm trying to run a for loop which inputs extracts values from the rtable for a variable after running a cox regression model. I'm running into an invalid syntax error and I'm not sure what could be causing it.
Here's the debugger log. Thanks in advance!

Code:
- mat `this_variable'_`l' = `mat_input'
= mat rsex_0 = 1, 1, 1, r(table)[1,1], r(table)[5,1], r(table)[6,1], 0 \ 1, 1, 
> 2, r(table)[1,2], r(table)[5,2], r(table)[6,2], 0 \ 1, 1, 3, r(table)[1,3], r
> (table)[5,3], r(table)[6,3], 0
invalid syntax