-
Notifications
You must be signed in to change notification settings - Fork 525
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
Add new article template for Bioinformatics #297
Conversation
Reference cannot work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I didn't check if there are other LaTeX files that are unnecessary (see the PR checklist), but at least plain.bst
is from a standard LaTeX package, hence shouldn't be included in the PR. I'm not sure where natbib.bst
comes from since it is not from a standard LaTeX package (is it provided by the journal?). The eps figure is relatively large in file size. I wonder if it is possible to use pdf (which will usually be much smaller). I'm asking because we should keep the package size as small as possible, otherwise R CMD check
will generate a NOTE in the log.
Thank you!
Thanks for your comments |
@yihui please see the updates, the files are provided by the journal at https://academic.oup.com/bioinformatics/pages/submission_online. I try to do my best to remove useless files. You can check them. |
Please also remember to close #83 if this PR is accepted :). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay. Now I only have two questions:
-
The file
OUP_First_SBk_Bot_8401-eps-converted-to.pdf
doesn't seem to be used anywhere. I wonder it can actually be removed. You can try it and see if the test fails. If it still succeeds, I'd just remove this file. -
Does the journal have a guideline on whether to use csl or bst for the bibliography style? Both are provided in this PR. If either is okay, I'd prefer using csl. Then delete
natbib.bst
and the default argumentcitation_package = 'natbib'
in the functionbioinformatics_article()
.
Thanks!
@yihui According to the description from https://academic.oup.com/bioinformatics/pages/submission_online, bst file is necessary, so I delete csl file. And the pdf is also necessary, in my test that removing the pdf, an error occurred. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great! You are all set now. The only thing we need from you is the contributor agreement, i.e. the first bullet in the checklist above. Have you signed that and emailed to JJ?
After we receive the agreement, we'll make a few very minor revisions to this PR and merge it. Thanks again for your contribution!
|
||
bibliography: bibliography.bib | ||
# biblio-style: natbib | ||
# csl: bioinformatics.csl |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Given that this file has been removed, perhaps this line could also be removed?
citation_package: natbib | ||
|
||
bibliography: bibliography.bib | ||
# biblio-style: natbib |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
On line #65
in template.tex
, the bibliography style has already been hard-coded, so I don't think this biblio-style
field is necessary here. It can confuse users because it may give them a wrong impression that the biblio-style
is customizable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@yihui Thanks, I agree with you. Could you directly change it in this PR web editor?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, I will.
@yihui I have done the contributor agreement. :) |
Okay. I'll let @cderv tweak and merge the PR. Thanks again! |
I can confirm that |
Thanks @ShixiangWang ! For next time, can you try to create a branch in your repo before sending a PR ? |
@cderv Thank you. Learned from it. :) |
I just saw a NOTE in
We'll have to either rename > nchar('rticles/inst/rmarkdown/templates/bioinformatics_article/skeleton/OUP_First_SBk_Bot_8401-eps-converted-to.pdf')
[1] 108 |
The pdf file is the one provided with the template. I don't know if it is important to keep the name or not.
If we do that we can reduce by more than 8 characters. Otherwise, we rename the file but we would need to modify the bioinfo.cls I think or we rename the function to |
Perhaps we just get rid of the $ ls inst/rmarkdown/templates/
acm_article bioinformatics_article jss_article rsos_article
acs_article biometrics_article mdpi_article rss_article
aea_article copernicus_article mnras_article sage_article
agu_article ctex oup_article sim_article
amq_article elsevier_article peerj_article springer_article
ams_article frontiers_article plos_article tf_article
arxiv_article ieee_article pnas_article
asa_article joss_article rjournal_article The suffix seems to be redundant anyway. |
Yes that is another way. We can do that. This folder name is only internal the |
To contribute a new article template to this package, please make sure you have done the following things (note that
journalname_article
below is only an example name):Unless you have done it in any other RStudio's projects before, please sign the individual or corporate contributor agreement for a significant pull request (it is fine not to sign it if a PR is only intended to fix a few typos). You can send the signed copy to jj@rstudio.com.
Add the
journalname_article()
function toR/article.R
if the output format is simple enough, otherwise create a separateR/journalname_article.R
.Add the Pandoc LaTeX template
inst/rmarkdown/templates/journalname_article/resources/template.tex
.Add a skeleton article
inst/rmarkdown/templates/journalname_article/skeleton/skeleton.Rmd
.Add a description of the template
inst/rmarkdown/templates/journalname_article/template.yaml
.Please include the document class file (
*.cls
) if needed, but please do not include standard LaTeX packages (*.sty
) that can be downloaded from CTAN. Please keep the number of new files absolutely minimal, and also make examples minimal (e.g., if you need a.bib
example, try to only leave one or two bibliography entries in it, and don't include one hundred items in it without using all of them).Update Rd and namespace (could be done by
devtools::document()
).Update NEWS.
Update README with a link to the newly supported journal.
Add a test to
tests/testit/test-formats.R
.Add your name to the list of authors
Authors@R
in DESCRIPTION. You don't need to bump the package version in DESCRIPTION.Lastly, please try your best to do only one thing per pull request (e.g., if you want to add two output formats, do them in two separate pull requests), and refrain from making cosmetic changes in the code base: https://yihui.name/en/2018/02/bite-sized-pull-requests/
Thank you!
I add this new template based on #83, so two authors are added to DESCRIPTION. Please correct my modification if there are something wrong.
This PR can close #83.
Best,
Shixiang