I encountered a strange expression as follows:
These two summary statistics are useful in looking for differences in the groups, and we are in for a surprise: an additional 8% of patients in the treatment group had a stroke!
It seems that I have never seen the preposition 'in' being used in a way like the two in's bolded in the above quote.
What's more, I cannot comprehend the 'looking for' after the first 'in' because I don't know what its subject is. Is the subject 'we' mentioned before the second 'in'?
What grammar rules am I missing?
Thanks in advance.