Solve this question in R I need all steps and Rcode Thank yo
Solve this question in R. I need all steps and R-code. Thank you
3
7
| Eye | ||||
| Hair | Brown | Blue | Hazel | Green |
| Black | 32 | 11 | 10 | 3 |
| Brown | 53 | 50 | 25 | 15 |
| Red | 10 | 10 | 7 | 7 |
| Blond | 3 | 30 | 5 | 8 |
Solution
The following table gives relative frequency colourwise for eyes and hair
Eye colour more prevalent is Blue
| Eye | Total | Rel freq | |||||||
| Hair | Brown | Rel freq | Blue | Rel freq | Hazel | rel freq | Green | ||
| Black | 32 | 11 | 10 | 3 | 56 | 0.200717 | |||
| Brown | 53 | 50 | 25 | 15 | 143 | 0.512545 | |||
| Red | 10 | 10 | 7 | 7 | 34 | 0.121864 | |||
| Blond | 3 | 30 | 5 | 8 | 46 | 0.164875 | |||
| Total | 98 | 101 | 47 | 33 | 279 | 1 | |||
| Rel frequ | 0.351254 | 0.362007 | 0.168459 | 0.11828 | 1 | 1 |
