Same-sex attraction in Iran appears to cluster within families and is linked to lower numbers of biological children in some groups, according to new research.