I am a new user. I need yours help I am puting one image.
I want to create new variable "D" in RStudio.
D is the SUM of number larger than the subject number VARIABLE A( 3,2,4,5) just for ID 1. Also i want to calculate automatically for ID 2,3...
Thank you for answer.