Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Combining 2 observations

    Lets say I have duplicates. And both sets of duplicates provide important information. Meaning one of the observations gives me some important information that the other does not have. I would like to combine them. How would i go about it?

    student_id cohort absent enrolled suspesnion
    0001 7 3 4 .
    0001 7 . . 6
    I want it to be
    student_id cohort absent enrolled suspesnion
    0001 7 3 4 6

    Additionally I have other variables which i have not included which is are just perfect duplicates and I can keep either observations.

  • #2
    Well, there may be a problem here. Look at that variable cohort. In your example, it has a non-missing value in both observations. Fortunately, in this instance, it has the same non-missing value. But if your data contains observations on the same student_id where cohort takes on different values, then what do you want to do to resolve the conflict?

    Assuming there are no conflicts of this nature, this is a simple task for -collapse-. See -help collapse- for details.

    Comment


    • #3
      Thank You!

      Comment

      Working...
      X