Dear Forum members,
I have a question regarding how to add values in different variables depending on condition. For instance, I have the following variables:
I would really appreciate your help.
Thank you.
Best,
Nathan
I have a question regarding how to add values in different variables depending on condition. For instance, I have the following variables:
- Item_ID
- Totaldue
- Saleprice
- Group_with
1) assign the average of the sum of the group to each "Item_ID" in the same group
2) and have another variable where I assign the sum to the "Item_ID" that has the lowest number among the group while putting value 0 to all other "Item_ID" in the same group.
I would really appreciate your help.
Thank you.
Best,
Nathan
Comment