I Keep Getting Invalid Syntax What Am I Doing Wrong R Python

I Keep Getting Invalid Syntax What Am I Doing Wrong R Python