0
$\begingroup$

I am using R. I have a column with 4 elements {car, bus, walk, train}. I would like to compare the car and bus with each other with the help of the 3 other columns. How can I do this?

For example, suppose that the other column is male/female, I would like to know how many are male or female for car and bus.

$\endgroup$
3
  • $\begingroup$ It is kind of row correlation $\endgroup$
    – sherek_66
    Aug 1, 2019 at 18:01
  • $\begingroup$ Perhaps this can be useful to you? $\endgroup$
    – Vlad_Z
    Aug 1, 2019 at 22:34
  • $\begingroup$ Do you want a table of counts for each pair of categories? Like table(d$vehicle, d$gender)? $\endgroup$
    – Spacedman
    Aug 2, 2019 at 7:31

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.