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

Updates to USGS citation style to conform to "USGS Suggestions to Authors 8th edition" #7477

Merged
merged 4 commits into from
Mar 22, 2025

Conversation

baagaard-usgs
Copy link
Contributor

Corrections based on "Suggestions to Authors of the Reports of the U.S. Geological Survey—The Official Style Guide of the U.S. Geological Survey, 8th Edition, Revised". This document is not yet publicly available, but I have verified that these style changes result in the correct formatting of references for datasets, software, journal articles, reports, and webpages.

  • Add dataset and software types.
  • Add DOIs to journal articles and reports using URL with accessed date.
  • Report: Use genre when available.
  • Webpage: Move institution to proper location.

Copy link

Awesome! You just created a pull request to the Citation Styles Language styles repository. One of our human volunteers will try to get in touch soon (usually within a week). In the meantime, I will run some automated checks. You should be notified of the results in a few minutes.

If you haven't done so yet, please make sure your style validates and follows all our other Style Requirements.

To update this pull request, visit the "Files changed" tab above, click on the ellipsis button in the top-right corner of your style, and then select "Edit file" to start editing:

If you have any questions, please leave a comment and we'll get back to you. While we usually respond in English, feel free to write in whatever language you're most comfortable.

Copy link

😃 Your submission passed all our automated tests.

Below are some sample citations generated based on your proposed changes:

us-geological-survey.csl (modified style)
(CSL search by example, 2012; Hancké and others, 2007)
(Fenner and others, 2019; Mares, 2001)

CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.
Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.
Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.
Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, in Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.
 (CSL search by example, 2012; Hancké and others, 2007)<br/>
 (Fenner and others, 2019; Mares, 2001)<br/>
 <hr/>
-CSL search by example, 2012, accessed December 15, 2012, at Citation Style Editor at http://editor.citationstyles.org/searchByExample/.<br/>
-Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28.<br/>
+CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.<br/>
+Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.<br/>
 Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.<br/>
 Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, <i>in</i> Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.<br/>

@adam3smith
Copy link
Member

You really want that rule for DOIs? That seems quite unnecessary and at odds with pretty much all other style guides. When will the new guidelines be published? We've made bad experiences (in the form of lots of complaints) publishing style updates before they went public

@github-actions github-actions bot added the waiting-for-response-from-contributor The ticket/pull request is awaiting input from the contributor/depositor label Mar 15, 2025
@adam3smith
Copy link
Member

Also, the way you have coded webpage doesn't look robust for (commonly) missing data -- check the auto generated example. Can you take a look?

@baagaard-usgs
Copy link
Contributor Author

The 8th edition of Suggestions to Authors is dated 2020 with the revised version dated August 2024. I don't know why the 8th edition is not public, but the citation styles appear stable.

The DOIs for all publication types are URLS (https://doi.org/DOI) accompanied by the data accessed.

I will check the webpage layout.

@github-actions github-actions bot removed the waiting-for-response-from-contributor The ticket/pull request is awaiting input from the contributor/depositor label Mar 15, 2025
@adam3smith
Copy link
Member

Oh, got it, misunderstood the 'not yet publicly available' part.

@github-actions github-actions bot added the waiting-for-response-from-contributor The ticket/pull request is awaiting input from the contributor/depositor label Mar 15, 2025
Copy link

😃 Your submission passed all our automated tests.

Below are some sample citations generated based on your proposed changes:

us-geological-survey.csl (modified style)
(CSL search by example, 2012; Hancké and others, 2007)
(Fenner and others, 2019; Mares, 2001)

CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.
Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.
Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.
Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, in Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.
 (CSL search by example, 2012; Hancké and others, 2007)<br/>
 (Fenner and others, 2019; Mares, 2001)<br/>
 <hr/>
-CSL search by example, 2012, accessed December 15, 2012, at Citation Style Editor at http://editor.citationstyles.org/searchByExample/.<br/>
-Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28.<br/>
+CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.<br/>
+Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.<br/>
 Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.<br/>
 Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, <i>in</i> Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.<br/>

Copy link

😃 Your submission passed all our automated tests.

Below are some sample citations generated based on your proposed changes:

us-geological-survey.csl (modified style)
(CSL search by example, 2012; Hancké and others, 2007)
(Fenner and others, 2019; Mares, 2001)

CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.
Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.
Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.
Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, in Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.
 (CSL search by example, 2012; Hancké and others, 2007)<br/>
 (Fenner and others, 2019; Mares, 2001)<br/>
 <hr/>
-CSL search by example, 2012, accessed December 15, 2012, at Citation Style Editor at http://editor.citationstyles.org/searchByExample/.<br/>
-Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28.<br/>
+CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.<br/>
+Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.<br/>
 Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.<br/>
 Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, <i>in</i> Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.<br/>

@baagaard-usgs
Copy link
Contributor Author

@adam3smith I thought I fixed the reference layout for the web page, but it still shows the colon before the title. Can you point me to the test input data, so I can understand what fields it is using?

@github-actions github-actions bot removed the waiting-for-response-from-contributor The ticket/pull request is awaiting input from the contributor/depositor label Mar 20, 2025
…tion.

Reference styles are provided in "Suggestions to Authors of the Reports of
the U.S. Geological Survey—The Official Style Guide of the U.S. Geological
Survey, 8th Edition, Revised". As of March 2025, this publication is an
internal USGS document. I added format information for common publication
types in comment at top of file.

- Add dataset and software types.
- Add DOIs to journal articles and reports using URL with accessed date.
- Report: Add option to use genre.
- Webpage: Move institution to proper location.
Copy link

😃 Your submission passed all our automated tests.

Below are some sample citations generated based on your proposed changes:

us-geological-survey.csl (modified style)
(CSL search by example, 2012; Hancké and others, 2007)
(Fenner and others, 2019; Mares, 2001)

CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.
Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.
Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.
Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, in Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.
 (CSL search by example, 2012; Hancké and others, 2007)<br/>
 (Fenner and others, 2019; Mares, 2001)<br/>
 <hr/>
-CSL search by example, 2012, accessed December 15, 2012, at Citation Style Editor at http://editor.citationstyles.org/searchByExample/.<br/>
-Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28.<br/>
+CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.<br/>
+Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.<br/>
 Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.<br/>
 Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, <i>in</i> Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.<br/>

1 similar comment
Copy link

😃 Your submission passed all our automated tests.

Below are some sample citations generated based on your proposed changes:

us-geological-survey.csl (modified style)
(CSL search by example, 2012; Hancké and others, 2007)
(Fenner and others, 2019; Mares, 2001)

CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.
Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.
Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.
Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, in Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.
 (CSL search by example, 2012; Hancké and others, 2007)<br/>
 (Fenner and others, 2019; Mares, 2001)<br/>
 <hr/>
-CSL search by example, 2012, accessed December 15, 2012, at Citation Style Editor at http://editor.citationstyles.org/searchByExample/.<br/>
-Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28.<br/>
+CSL search by example, 2012, : Citation Style Editor, accessed December 15, 2012, at http://editor.citationstyles.org/searchByExample/.<br/>
+Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.<br/>
 Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.<br/>
 Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, <i>in</i> Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.<br/>

Copy link
Member

@bwiernik bwiernik left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a comment on one line about using delimiter instead of prefix/suffix. Can you please make that change throughout the style?

</group>
</else-if>
<else-if type="software">
<group suffix=":">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You should almost never include punctuation like this as a prefix or suffix, as it will show even if there is no text following. Use "delimiter" instead.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The format is [title] [version]:. USGS style is to either include the version in the title or include it in the version field. I want the colon after version if both are given and after the title if just the title is given. Isn't it safe to require a title?

Copy link
Member

@bwiernik bwiernik Mar 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In general, you should not assume that any piece of data is present and instead write the style to be robust to missing data. An untitled piece of software might have just a medium/genre and no title for example.

@baagaard-usgs
Copy link
Contributor Author

Here is the code I have for typesetting the title and container-title for a web page. Zotero is using the container-title if the title is empty, which is what I thought the problem was in typesetting the "CSL search by example" case in the test.

In the test case, is title empty? What field is providing "Citation Style Editor"?

	    <choose>
	      <if variable="title">
		<text variable="title"/>
		<choose>
		  <if variable="container-title">
		    <text variable="container-title" prefix=": "/>
		  </if>
		</choose>
	      </if>
	      <else-if variable="container-title">
		<text variable="container-title"/>
	      </else-if>
	    </choose>

Copy link

😃 Your submission passed all our automated tests.

Below are some sample citations generated based on your proposed changes:

us-geological-survey.csl (modified style)
(CSL search by example, 2012; Hancké and others, 2007)
(Fenner and others, 2019; Mares, 2001)

CSL search by example, 2012, Citation Style Editor, accessed December 15, 2012 at http://editor.citationstyles.org/searchByExample/.
Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.
Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.
Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, in Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.
 (CSL search by example, 2012; Hancké and others, 2007)<br/>
 (Fenner and others, 2019; Mares, 2001)<br/>
 <hr/>
-CSL search by example, 2012, accessed December 15, 2012, at Citation Style Editor at http://editor.citationstyles.org/searchByExample/.<br/>
-Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28.<br/>
+CSL search by example, 2012, Citation Style Editor, accessed December 15, 2012 at http://editor.citationstyles.org/searchByExample/.<br/>
+Fenner, M., Crosas, M., Grethe, J.S., Kennedy, D., Hermjakob, H., Rocca-Serra, P., Durand, G., Berjon, R., Karcher, S., Martone, M., and Clark, T., 2019, A data citation roadmap for scholarly data repositories: Scientific Data, v. 6, no. 1, p. 28, accessed April 27, 2019, at https://doi.org/10.1038/s41597-019-0031-8.<br/>
 Hancké, B., Rhodes, M., and Thatcher, M. (Eds.), 2007, Beyond varieties of capitalism: Conflict, contradiction, and complementarities in the European economy: Oxford University Press, Oxford and New York.<br/>
 Mares, I., 2001, Firms and the welfare state: When, why, and how does social policy matter to employers?, <i>in</i> Hall, P.A. and Soskice, D. eds., Varieties of capitalism. The institutional foundations of comparative advantage: Oxford University Press, New York, p. 184–213.<br/>

@baagaard-usgs baagaard-usgs requested a review from bwiernik March 20, 2025 23:57
@adam3smith
Copy link
Member

This looks good. I think the issue was that title is used as a substitute element for author, so it gets omitted later on but still tests as true

@github-actions github-actions bot added the waiting-for-response-from-contributor The ticket/pull request is awaiting input from the contributor/depositor label Mar 22, 2025
@adam3smith adam3smith merged commit 0328bbe into citation-style-language:master Mar 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waiting-for-response-from-contributor The ticket/pull request is awaiting input from the contributor/depositor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants