Citations of different authors sharing the same surname.

Dear all,

I need to cite two authors who share the same surname but have different given names. My automatic citation style does not distinguish between them. How can I configure it to include the first initial only for those authors with identical surnames?

Eg.: A. Doe (2022); J. Doe (2021); McDonalds (2005)

Thanks!
  • APA and Chicago styles do this automatically. It's basically
    disambiguate-add-givenname="true" givenname-disambiguation-rule="primary-name-with-initials"
  • I'm using another format.
    Where should I add this notation?
  • edited yesterday at 8:39pm
    I found it, but it's not working as I'd like.

    The result is Doe, John, 2005; Doe, Andrew, 2012 and I'd like only the initial



    The code:


    <citation et-al-min="4" et-al-use-first="1" disambiguate-add-year-suffix="true" disambiguate-add-givenname="true" givenname-disambiguation-rule="primary-name-with-initials" collapse="year" delimiter-precedes-et-al="never">
    <sort>
    <key macro="author"/>
    <!-- ordena primeiro pela macro autor -->
    <key variable="issued"/>
    <!-- em seguida pela data -->
    <key variable="year-suffix"/>
    </sort>
    <layout prefix="(" suffix=")" delimiter="; ">
    <!-- citações entre parênteses, separando mais de um documento com ponto-e-vírgula -->
    <choose>
    <if match="any" disambiguate="true">
    <text variable="title" form="short" font-style="normal"/>
    </if>
    </choose>
    <choose>
    <if type="broadcast motion_picture song" match="any">
    <!-- documentos em que citação é pelo título -->
    <group>
    <text variable="title" form="short" suffix=", "/>
    <text macro="issued-year"/>
    </group>
    </if>
    <else-if type="musical_score" match="any">
    <!-- documentos em que citação é pelo título -->
    <group>
    <text macro="author-short" suffix=", "/>
    <text macro="issued-year"/>
    <text macro="citation-locator" prefix=", "/>
    </group>
    </else-if>
    <else>
    <!-- do contrário é o formato padrão de autor e data separados por vírgula -->
    <group>
    <text macro="author-short" suffix=", "/>
    <text macro="issued-year"/>
    <text macro="citation-locator" prefix=", "/>
    </group>
    </else>
    </choose>
    </layout>
    </citation>
  • Look at the author-short macro and fix the given name there
  • I found it but I don't have any idea how to edit it to appear only first letter and only when authors have same surname


    <macro name="author-short">
    <!-- Macro responsável por mostrar o autor na citação -->
    <choose>
    <if type="broadcast motion_picture song" match="any">
    <text variable="title" form="short" text-case="uppercase" quotes="false"/>
    </if>
    <else-if type="musical_score" match="any">
    <names variable="composer">
    <name form="short" delimiter="; " delimiter-precedes-last="never" initialize-with=". " name-as-sort-order="all">
    <name-part name="family"/>
    <name-part name="given"/>
    </name>
    </names>
    </else-if>
    <else>
    <names variable="author">
    <name form="short" delimiter="; " delimiter-precedes-last="never" initialize-with=". " name-as-sort-order="all">
    <name-part name="family"/>
    <name-part name="given"/>
    </name>
    <et-al font-style="italic"/>
    <substitute>
    <names variable="editor"/>
    <names variable="translator"/>
    <choose>
    <if type="book">
    <!-- uso do título quando não houver autor -->
    <text variable="title" form="short"/>
    </if>
    <else>
    <text variable="title" form="short" quotes="false"/>
    </else>
    </choose>
    </substitute>
    </names>
    </else>
    </choose>
    </macro>
Sign In or Register to comment.