New member
- Joined
- Feb 7, 2023
- Messages
- 21
- Thread Author
- #1
If I have a dataframe like this:
I would like to remove duplicated PAIRS only. i.e. The first pair and second pair of .565333 timestamps are actually unique, but doing something like t[~t.duplicated()] will remove all the duplicates like this:
whereas instead I want this:
Code:
Time X Y
2023-02-01T15:03:02.565333 200 10.1
2023-02-01T15:03:02.565333 200 10.1
2023-02-01T15:03:02.565333 200 10.1
2023-02-01T15:03:02.565333 200 10.1
2023-02-01T15:03:02.634508 200 10.1
2023-02-01T15:03:02.634508 200 10.1
2023-02-01T15:03:02.943522 200 10.1
2023-02-01T15:03:02.943522 200 10.1
I would like to remove duplicated PAIRS only. i.e. The first pair and second pair of .565333 timestamps are actually unique, but doing something like t[~t.duplicated()] will remove all the duplicates like this:
Code:
2023-02-01T15:03:02.565333 200 10.1
2023-02-01T15:03:02.634508 200 10.1
2023-02-01T15:03:02.943522 200 10.1
whereas instead I want this:
Code:
2023-02-01T15:03:02.565333 200 10.1
2023-02-01T15:03:02.565333 200 10.1
2023-02-01T15:03:02.634508 200 10.1
2023-02-01T15:03:02.943522 200 10.1