Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Disambiguation by initials #408

Open
twsh opened this issue Jul 17, 2019 · 4 comments

Comments

Projects
None yet
3 participants
@twsh
Copy link

commented Jul 17, 2019

I have found some behaviour that seems strange to me. I have a bibliography like this:

@article{smith1,
	title = {Foo},
	author = {Smith, Mary},
	date = {2019}
}

@article{smith2,
	title = {Bar},
	author = {Smith, Mary},
	date = {2018}
}

@article{smithsmith,
	title = {Foo bar},
	author = {Smith, Mary and Smith, John},
	date = {2019}
}

And a markdown file like this:

@smithsmith
@smith1
@smith2

The output from $ pandoc --bibliography=mwe.bib mwe.md is:

<p><span class="citation" data-cites="smithsmith">M. Smith and Smith (2019)</span> <span class="citation" data-cites="smith1">M. Smith (2019)</span> <span class="citation" data-cites="smith2">Smith (2018)</span></p>
<div id="refs" class="references">
<div id="ref-smith2">
<p>Smith, Mary. 2018. “Bar.”</p>
</div>
<div id="ref-smith1">
<p>———. 2019. “Foo.”</p>
</div>
<div id="ref-smithsmith">
<p>Smith, Mary, and John Smith. 2019. “Foo Bar.”</p>
</div>
</div>

What seems to be happening is that when an initial is added to disambiguate an author in a citation, other items with that author and the same year also have an initial added. Items with a different year do not.

Because I am not specifying a CSL file, the behaviour must be coming from the default chicago-author-date.csl. If I use a CSL file which uses the default disambiguation rule (givenname-disambiguation-rule="by-cite"), I get no initials.

This might be related to #38
I am using pandoc 2.2.1 and pandoc-citeproc 0.14.3.1.

@jgm

This comment has been minimized.

Copy link
Owner

commented Jul 17, 2019

Could you say what output you were expecting here?

@twsh

This comment has been minimized.

Copy link
Author

commented Jul 18, 2019

I think that this is what it should be:

<p><span class="citation" data-cites="smithsmith">M. Smith and Smith (2019)</span> <span class="citation" data-cites="smith1">M. Smith (2019)</span> <span class="citation" data-cites="smith2">M. Smith (2018)</span></p>
<div id="refs" class="references">
<div id="ref-smith2">
<p>Smith, Mary. 2018. “Bar.”</p>
</div>
<div id="ref-smith1">
<p>———. 2019. “Foo.”</p>
</div>
<div id="ref-smithsmith">
<p>Smith, Mary, and John Smith. 2019. “Foo Bar.”</p>
</div>
</div>

If I understand what's described at http://docs.citationstyles.org/en/1.0.1/specification.html#disambiguation correctly, there should be disambiguation of ambiguous names, e.g., 'Smith', by adding an initial, but only the first name in each citation. So 'Smith (2018)' should be 'M. Smith 2019'. That's with the “primary-name” option that the default CSL has.

@adam3smith

This comment has been minimized.

Copy link

commented Jul 18, 2019

Hi -- co-maintainer of CSL here.
@twsh raised this over at Zotero, but let me chime in here, too: The expected behavior of givenname-disambiguation with the rule set to primary-name is to compare all first authors and add initials to a set of authors if and only if they are different authors (different given name) with the same last name.

i.e. in the example above, we would expect
(Smith 2018, Smith 2019, Smith and Smith 2019)
since Mary is the first author of all of the works. If the author order of the Smith and Smith citation were reversed, we would expect
(M. Smith 2018, M. Smith 2019, J. Smith and Smith 2019)

Hope that makes sense

@twsh

This comment has been minimized.

Copy link
Author

commented Jul 18, 2019

Thanks @adam3smith

It looks like what I ought to have expected, the correct behaviour, is this:

<p><span class="citation" data-cites="smithsmith">Smith and Smith (2019)</span> <span class="citation" data-cites="smith1">Smith (2019)</span> <span class="citation" data-cites="smith2">Smith (2018)</span></p>
<div id="refs" class="references">
<div id="ref-smith2">
<p>Smith, Mary. 2018. “Bar.”</p>
</div>
<div id="ref-smith1">
<p>———. 2019. “Foo.”</p>
</div>
<div id="ref-smithsmith">
<p>Smith, Mary, and John Smith. 2019. “Foo Bar.”</p>
</div>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.