# Examples showing the difference between dummy variables and binary variables?

So I understand that dummy variables and binary variables are not the same thing. Here are my definitions of both (please correct if I am wrong):

• Dummy: Categorizes variables that don’t have any relationship with each other with the numbers 0 or 1.
• Binary: Any variable that has only 2 values.

However, I cant think of a example where something is only a binary variable but not a dummy variable?

Eg. If I code 0 as Caucasian, 1 as African American, this is a binary variable because it only can be 2 values. However, I'm pretty sure this is also a dummy variable even though they do have a relationship with each other (race)?

Eg 2. Even if you do the classic example of 0 = male, 1 = female, this is a binary variable because it only can be 2 values. However, I'm pretty sure this is also a dummy variable even though they do have a relationship with each other (gender)?

Your definitions mostly are fine. I would just add that "don’t have any relationship with each other" may not be precisely true depending on what you mean by "relationship". If I have a coin with sides $$\text{Heads}$$ and $$\text{Tails}$$ I can certainly map them $$\phi : \{ \text{Heads}, \text{Tails}\} \mapsto \{ 0, 1 \}$$ while they have a relationship of being opposing sides of a coin, and might be assumed to be mutually exclusive events for a probabilistic model.
Since a dummy variable has two values, it is a binary variable. You can even consider maps $$\phi: \{0,1 \} \mapsto \{0,1 \}$$ where one is an involution and another is a bit flip (and the others represent some other Boolean-like functions).