dimanche 24 novembre 2019

How can I sum and count rows on certain conditions in SPSS (or in r)

Problem: A company ("pdpass") can have several patents per year.

Target state:

1) For the variables "allcites" and "hjwt" I want to add the duplicate cases to the corresponding primary cases (related to a certain year). So I could delete the duplicate cases without losing any information.

2) I want to create a new variable that counts the number of patents for a "pdpass" for each year.

Thank you very much:)

variable view

data view

Aucun commentaire:

Enregistrer un commentaire