I can't see transgender as being heriditory simply because there doesn't appear to be any evidence for it.
We could propose that, many are transgender, and/or homosexual but avoid facing up to it for fear of social stigma. That, however, seems to be a large presumption.
I don't know anything about epigentics (yet), so I can't comment.
I did a paper in the early 70s looking at homosexuality. (I didn't include transgender at the time. That was what I was really thinking about but there was very little information on the subject and I just considerd myself as really weird. Perhaps, seeking to change to justify my homosexuality).
I discovered examples of homosexuality going back to the earliest points of history. I looked, as far as I could, at the nature of feral societies and conjectued the sort of lifestyle they probably lived. Nothing can be proven, of course, but working on the principal that a feral society would seek to the easiest way to survive in a hostile, wandering environment, I believe my conjecture was probably near reality.
There seems to be a place for homosexual people. I say this because the males and the females in a tribe would necessarily need to be separated, while the males went to hunt. The previous proposal, that some males would remain to guard the females would mean that these would lose their place within the male peer group. Homosexuals, especially if they are efiminate, would have little interest in a the male peer group place.
Now I went on to conjecture that this sub group, homosexuals, didn't generally breed. If they did then they might have been seen as a risk to the females. Therefore, the persistance of homosexuals, their continual emergence in recorded history, inspite of persecution, principally in Africa and the ME, together with the significant numbers that seem to exist today would seem to be more than simple genetic traits.
I fully accept arguments on my point about homosexuals not breeding. The issue is quite complicated however.
Epigentics may well open some new areas of thought.