I have an id variable (product), a time variable (month), a revenue variable (sales) and a lot of other variables
I want to make a new variable with info on product sales in the final month. I want this variable to have the value of the sales of a product in the final month, but I want it to also apply for the same product in different months. That is, this new var needs to only change value when id is changing value. Meaning all the same id's (products) needs to have the same respective values on this new var.
What commands should I use?
I want to make a new variable with info on product sales in the final month. I want this variable to have the value of the sales of a product in the final month, but I want it to also apply for the same product in different months. That is, this new var needs to only change value when id is changing value. Meaning all the same id's (products) needs to have the same respective values on this new var.
What commands should I use?
Comment