It can be. Not necessarily but sometimes would be the answer.
I think what we know is that certain personality types may be more predisposed. If you're an anxious child, or if you have a lot of worry in your family, or as Lisa mentioned, any sort of mental illness in itself, we notice there can be a genetic component. It doesn't have to just be an eating disorder, but if there's depression or if there's anxiety, that can play a role.