0

I'm trying to calculate the frequency of a certain event occurring by combining the data from several groups with the same name but at different time points. I also need to collate data from a range of groups in one group. It sounds a bit confusing, but what I mean is:

|Name x min| 1        | 2        |3         |4         | 5        |
| A1       |n         | event2   |  event1  |n         |  event1  |
| B1       |n         | n        | n        |  event   |  event2  |
| C1       |  event1  | n        |   event1 | n        |  event1  |
| A2       |  event1  |   event2 | n        |   event2 |  event1  |

So, for example, I need to calculate how many times the "event1" occurred in group A (including both A1 and A2) on the 1 minute, how many on 2 minute, and so on. I feel like I am very-very stuck, even though the solution is probably horribly simple

user438383
  • 5,716
  • 8
  • 28
  • 43
Vvvvvv
  • 1
  • 1
    Greetings! Usually it is helpful to provide a minimally reproducible dataset for questions here so people can troubleshoot your problems (rather than a table or screenshot for example). One way of doing is by using the `dput` function on the data or a subset of the data you are using, then pasting the output into your question. You can find out how to use it here: https://youtu.be/3EID3P1oisg – Shawn Hemelstrand Jan 23 '23 at 14:40

0 Answers0