Hello, I know there are different ways to do what I want to do but I just can manage to make it work.. I would like to do this in a proc SQL in one select statement. I have this table named test. I want to create a new column (D_IL8) that would be IL8 - (mean IL8 for positive outcomes) Mean IL8 for positive outcomes = (34+23+34+28+27)/5 = 29.20 So column D-IL8 would be IL8 value for that person - 29.20 Name IL8 Outcome D_IL8 Marie 34,00 Positive Martha 56,00 Negative Angela 23,00 Positive Jodie 34,00 Positive Alexe 44,00 Negative Jane 33,00 Negative Cassandra 28,00 Positive Olivia 27,00 Positive Anna 41,00 Negative Sarah 42,00 Negative Does anyone knows how to do that ? Thank you so much
... View more