Skip to content
Snippets Groups Projects
Unverified Commit b307b16a authored by Chris Holdgraf's avatar Chris Holdgraf Committed by GitHub
Browse files

Merge pull request #529 from choldgraf/docs_clean_update

parents 96a9fe61 00a3d35b
No related branches found
No related tags found
No related merge requests found
...@@ -35,17 +35,18 @@ with the `{bibliography}` directive. ...@@ -35,17 +35,18 @@ with the `{bibliography}` directive.
2. **Add references**. Add some references to your BibTex file. See 2. **Add references**. Add some references to your BibTex file. See
[the BibTex documentation](http://www.bibtex.org/Using/) for information about [the BibTex documentation](http://www.bibtex.org/Using/) for information about
the BibTex reference style. Here's the example from above: the BibTex reference style. Here's an example citation:
``` ```
@InProceedings{ project_jupyter-proc-scipy-2018, @article{perez2011python
author = { {P}roject {J}upyter and {M}atthias {B}ussonnier and {J}essica {F}orde and {J}eremy {F}reeman and {B}rian {G}ranger and {T}im {H}ead and {C}hris {H}oldgraf and {K}yle {K}elley and {G}ladys {N}alvarte and {A}ndrew {O}sheroff and {M} {P}acer and {Y}uvi {P}anda and {F}ernando {P}erez and {B}enjamin {R}agan-{K}elley and {C}arol {W}illing }, , title = {Python: an ecosystem for scientific computing}
title = { {B}inder 2.0 - {R}eproducible, interactive, sharable environments for science at scale }, , author = {Perez, Fernando and Granger, Brian E and Hunter, John D}
booktitle = { {P}roceedings of the 17th {P}ython in {S}cience {C}onference }, , journal = {Computing in Science \\& Engineering}
pages = { 113 - 120 }, , volume = {13}
year = { 2018 }, , number = {2}
editor = { {F}atih {A}kici and {D}avid {L}ippa and {D}illon {N}iederhut and {M} {P}acer }, , pages = {13--21}
doi = { 10.25080/Majora-4af1f417-011 } , year = {2011}
, publisher = {AIP Publishing}
} }
``` ```
3. **Add a citation**. In your content, add the following text to include a citation 3. **Add a citation**. In your content, add the following text to include a citation
...@@ -57,18 +58,18 @@ with the `{bibliography}` directive. ...@@ -57,18 +58,18 @@ with the `{bibliography}` directive.
For example, this text For example, this text
``` ```
{cite}`project_jupyter-proc-scipy-2018` {cite}`perez2011python`
``` ```
generates this citation: {cite}`project_jupyter-proc-scipy-2018` generates this citation: {cite}`perez2011python`
You can also include multiple citations in one go, like so: You can also include multiple citations in one go, like so:
``` ```
{cite}`project_jupyter-proc-scipy-2018,holdgraf_rapid_2016` {cite}`perez2011python,holdgraf_rapid_2016,RePEc:the:publsh:1367,caporaso2010qiime`
``` ```
becomes {cite}`project_jupyter-proc-scipy-2018,holdgraf_rapid_2016`. becomes {cite}`perez2011python,holdgraf_rapid_2016,RePEc:the:publsh:1367,caporaso2010qiime`.
4. **Add a bibliography**. Use the following directive to do so: 4. **Add a bibliography**. Use the following directive to do so:
...@@ -77,10 +78,9 @@ with the `{bibliography}` directive. ...@@ -77,10 +78,9 @@ with the `{bibliography}` directive.
``` ```
```` ````
This will generate a bibliography for your entire bibtex file, like so: This will generate a bibliography for your entire bibtex file. See
[the bibliography at the end of this page](citations/bibliography) for an example.
```{bibliography} ../references.bib
```
When your book is built, the bibliography and citations will now be included. When your book is built, the bibliography and citations will now be included.
...@@ -97,6 +97,11 @@ jupyter-book clean mybookname/ ...@@ -97,6 +97,11 @@ jupyter-book clean mybookname/
See {ref}`clean-build` for more information. See {ref}`clean-build` for more information.
```` ````
See the [`sphinxcontrib-bibtex documentation`](https://sphinxcontrib-bibtex.readthedocs.io/en/latest/usage.html#roles-and-directives)
for more information about how to use this feature. Though note the documentation
is written for rST and you'll need to adapt the directive/role syntax for your
markdown content.
(labels-and-refs)= (labels-and-refs)=
## Cross-references and labels ## Cross-references and labels
...@@ -134,3 +139,9 @@ content you'd like to reference. Here is a quick overview of some common options ...@@ -134,3 +139,9 @@ content you'd like to reference. Here is a quick overview of some common options
* `{numref}` is used to provide *numbered* references to figures * `{numref}` is used to provide *numbered* references to figures
* `{doc}` is used to reference other files in your book * `{doc}` is used to reference other files in your book
* `{eq}` is used to reference equations that have been given a `label` value * `{eq}` is used to reference equations that have been given a `label` value
(citations/bibliography)=
## Bibliography
```{bibliography} ../references.bib
```
@article{perez2011python
, title = {Python: an ecosystem for scientific computing}
, author = {Perez, Fernando and Granger, Brian E and Hunter, John D}
, journal = {Computing in Science \\& Engineering}
, volume = {13}
, number = {2}
, pages = {13--21}
, year = {2011}
, publisher = {AIP Publishing}
}
@article{holdgraf_rapid_2016, @article{holdgraf_rapid_2016,
title = {Rapid tuning shifts in human auditory cortex enhance speech intelligibility}, title = {Rapid tuning shifts in human auditory cortex enhance speech intelligibility},
volume = {7}, volume = {7},
...@@ -13,12 +25,24 @@ ...@@ -13,12 +25,24 @@
} }
@Inproceedings{ project_jupyter-proc-scipy-2018, @article{RePEc:the:publsh:1367
author = { {P}roject {J}upyter and {M}atthias {B}ussonnier and {J}essica {F}orde and {J}eremy {F}reeman and {B}rian {G}ranger and {T}im {H}ead and {C}hris {H}oldgraf and {K}yle {K}elley and {G}ladys {N}alvarte and {A}ndrew {O}sheroff and {M} {P}acer and {Y}uvi {P}anda and {F}ernando {P}erez and {B}enjamin {R}agan-{K}elley and {C}arol {W}illing }, , src = {repec.org}
title = { {B}inder 2.0 - {R}eproducible, interactive, sharable environments for science at scale }, , title = {Stochastic stability in monotone economies}
booktitle = { {P}roceedings of the 17th {P}ython in {S}cience {C}onference }, , author = {Stachurski, John and Kamihigashi, Takashi}
pages = { 113 - 120 }, , journal = {Theoretical Economics}
year = { 2018 }, , year = {2014}
editor = { {F}atih {A}kici and {D}avid {L}ippa and {D}illon {N}iederhut and {M} {P}acer }, , volume = {9}
doi = { 10.25080/Majora-4af1f417-011 } , issue = {2}
}
@article{caporaso2010qiime
, title = {QIIME allows analysis of high-throughput community sequencing data}
, author = {Caporaso, J Gregory and Kuczynski, Justin and Stombaugh, Jesse and Bittinger, Kyle and Bushman, Frederic D and Costello, Elizabeth K and Fierer, Noah and Pena, Antonio Gonzalez and Goodrich, Julia K and Gordon, Jeffrey I and others}
, journal = {Nature methods}
, volume = {7}
, number = {5}
, pages = {335--336}
, year = {2010}
, publisher = {Nature Publishing Group}
} }
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment