Package knitcitations

Similar documents
Package RSentiment. October 15, 2017

Writing Package Vignettes

Package colorpatch. June 10, 2017

Package machina. October 7, 2016

Package hcandersenr. January 20, 2019

Package schoenberg. June 26, 2018

INTRODUCTION TO ENDNOTE

LMS301: Reference Management Software (Mendeley)

Introduction to Research Department of Metallurgical and Materials Engineering Indian Institute of Technology, Madras

EndNote Web. Quick Reference Card THOMSON SCIENTIFIC

Introduction to Mendeley

Package painter. August 13, 2018

Semantic annotation of publication entities using the SPAR (Semantic Publishing and Referencing) Ontologies

Enriching scientific citations to facilitate knowledge discovery

DIGITAL MEASURES BIBTEX AND PUBMED IMPORT- MANUAL

EasyBib Pro Quick How To Where students can create citations, compile their source notes, and create an outline.

All about Mendeley. University of Southampton 18 May mendeley.com. Michaela Kurschildgen, Customer Consultant Elsevier

Getting started with Mendeley

Reference management software - EndNote. Presenters: Research Support Team Libraries, Research & Learning Resources

Citation, Ethics, Plagiarism

biblatex-mla MLA Style Using Biblatex James Clawson 1 Version Note 1 2 Introduction 1

Introduction to Endnote X8 Handbook

Reference sheet for natbib usage (Describing version 7.1 from 2003/06/06)

Editing Your Reading List

Supplementary Note. Supplementary Table 1. Coverage in patent families with a granted. all patent. Nature Biotechnology: doi: /nbt.

Introduction to EndNote X7

INTRODUCTION TO ENDNOTE. NTNU University Library, Medicine and Health Library January 2017

Introduction to Citation Management Software

TUGboat, Volume 37 (2016), No heading. category: collator: foreword:

Dead Links? No Problem. We re In This Together

Staff User s Guide Course Reading and Reserves. Version 22

How to Use Noodlebib to Create a JOURNAL Citation in MLA Style

Package rasterimage. September 10, Index 5. Defines a color palette

EndNote X6 with Word 2007

Academic Identity: an Overview. Mr. P. Kannan, Scientist C (LS)

Editing Reference Types & Styles: Macintosh. EndNote Support & Training October 2017

Information literacy Masters engineering science

DRAFT UC VENDOR/SHARED CATALOGING STANDARDS FOR AUDIO RECORDINGS JUNE 4, 2013 EDIT

Reference sheet for natbib usage (Describing version 8.0 from 2007/02/05)

Writing scientific papers 10/8/07

***Please be aware that there are some issues of compatibility between all current versions of EndNote and macos Sierra (version 10.12).

Purdue Libraries Publishing Services: The Domino Effect of Repository-Based Publishing, Outreach, and Promotion

Package ForImp. R topics documented: February 19, Type Package. Title Imputation of Missing Values Through a Forward Imputation.

Writing Research Essays:

How to Use Noodlebib to Create a JOURNAL Citation in MLA Style

Essential EndNote X7.

Reference sheet for natbib usage (Describing version 8.31b from 2010/09/13)

IST Get It + Document Delivery. User Guide

A GUIDE TO USING ENDNOTE

ICI JOURNALS MASTER LIST Detailed Report for 2017

The Organization and description of the UNLV archives

What s New in MLA Style? (Version 8) IU East Writing Center

Apa Format Electronic Source No Author Reference List

Chapter 3 sourcing InFoRMAtIon FoR YoUR thesis

EndNote X6: the basics (downloadable desktop version)

ISO INTERNATIONAL STANDARD. Bibliographic references and source identifiers for terminology work

EndNote for Windows. Take a class. Background. Getting Started. 1 of 17

OMA Device Management Server Delegation Protocol

Endnote Workbook with exercises

Desktop. Basic use of EndNote. Important start info 3 tips p. 1. Entering references manually p. 3

Tutor Led Manual v1.7. Table of Contents PREFACE I.T. Skills Required Before Attempting this Course... 1 Copyright... 2 GETTING STARTED...

Literature Management with EndNote

Measuring Your Research Impact: Citation and Altmetrics Tools

EndNote Online. Getting Started Guide (Windows)

EndNote Essentials. EndNote Overview PC. KUMC Dykes Library

Mendeley. By: Mina Ebrahimi-Rad (Ph.D.) Biochemistry Department Head of Library & Information Center Pasteur Institute of Iran

administration access control A security feature that determines who can edit the configuration settings for a given Transmitter.

Introduction to EndNote

Writing Research Essays:

Introduction to Mendeley

USING THE WEB TO CHANGE EDITORIAL RESEARCH PRACTICE. Patrick Golden & Michael Buckland Pacific Neighborhood Consortium December 7, 2012

CRIS with in-text citations as interactive entities. Sergey Parinov CEMI RAS and RANEPA

EndNote Online Getting Started Workbook

The Reference Librarian Face-to-Face with Reference Management

48 TV Caller ID TV CALLER ID

EndNote X7 Getting Started. (adapted with permission from Thompson 2006)

ENDNOTE X4. Service Desk Health Sciences Library Main Campus EndNote Contacts:

Final Exam Review Worksheet

Analyzing Modulated Signals with the V93000 Signal Analyzer Tool. Joe Kelly, Verigy, Inc.

EndNote X8. Research Smarter. Online Guide. Don t forget to download the ipad App

(web semantic) rdt describers, bibliometric lists can be constructed that distinguish, for example, between positive and negative citations.

The digital revolution and the future of scientific publishing or Why ERSA's journal REGION is open access

Instructions to Authors

Inventory Software Trials

APA Research Paper Chapter 2 Supplement

Book Indexes p. 49 Citation Indexes p. 49 Classified Indexes p. 51 Coordinate Indexes p. 51 Cumulative Indexes p. 51 Faceted Indexes p.

USING THE AUSTRALIAN GUIDE TO LEGAL CITATION (3rd edition) WITH ENDNOTE X6 or ENDNOTE X7

Suggestor.step.scopus.com/suggestTitle.cfm 1

Introduction to EndNote Desktop

Today s WorldCat: New Uses, New Data

Directions: Please complete study guide in preparation for Semester 1 Final Exam.

^a Place of publication: e.g. Rome (Italy) ; Oxford (UK) ^b Publisher: e.g. FAO ; Fishing News Books

EndNote X6 Basics. Health Sciences Library System University of Pittsburgh

EndNote Tutorial Handout Table of Contents

The following example shows creating an instance of the Files View, name FILES, version view called "MyFiles".

Assignment 6: Essay Sample

WORKING NOTES AS AN. Michael Buckland, School of Information, UC Berkeley Andrew Hyslop, California State Archives. April 13, 2013

Positive Attendance. Overview What is Positive Attendance? Who may use Positive Attendance? How does the Positive Attendance option work?

APA STYLE GUIDE FOR BIBLIOGRAPHICAL CITATIONS

The Open University s repository of research publications and other research outputs

Transcription:

Package knitcitations March 18, 2013 Type Package Title Citations for knitr markdown files Version 0.4-4 knitcitations provides the ability to create dynamic citations in which the bibliographic information is pulled from the web rather than having to be entered into a local database such as bibtex ahead of time. Knitcitations is primarily aimed at authoring in the R markdown format, and can provide outputs for web-based authoring such as linked text and tooltips over inline citations. Cite using a DOI, URL, or bibtex file key. See the package URL for details. URL https://github.com/cboettig/knitcitations Depends R (>= 2.15.0), knitr, bibtex Imports xtable, RCurl, XML, httr Suggests testthat License CC0 Collate functiontable.r bibliography.r formatref.r ref.r cite.r create_bibkey.r citep.r citet.r read.bibtex.r write.b Author Carl Boettiger [aut, cre] Maintainer Carl Boettiger <cboettig@gmail.com> NeedsCompilation no Repository CRAN Date/Publication 2013-03-18 21:26:33 1

2 authoryear_p R topics documented: authoryear_p........................................ 2 authoryear_t......................................... 3 bibliography......................................... 3 cite.............................................. 4 citep............................................. 5 citet............................................. 6 cite_options......................................... 7 cleanbib........................................... 8 format_authoryear_p.................................... 8 format_authoryear_t.................................... 9 functiontable........................................ 9 greycite........................................... 10 newbib............................................ 10 numeral........................................... 11 read.bibtex......................................... 11 ref.............................................. 12 write.bibtex......................................... 12 write_cache......................................... 13 Index 14 authoryear_p format the author and year This is just a utility function that calls format_authoryear_p, which does the actual formating at the time the citation is added to the data. This provides a separate API for the function that simply returns the formatted text, from the function that does the formatting (which may change, or may have more flavors, etc). authoryear_p(entry, format_inline_fn = format_authoryear_p) entry a bibentry format_inline_fn the function that actually creates the inline format for a single entry the author-year citation

authoryear_t 3 authoryear_t format the author and year format the author and year authoryear_t(entry, format_inline_fn = format_authoryear_t) entry a bibentry format_inline_fn the function that actually creates the inline format for a single entry the author-year citation bibliography Generate the bibliography Generate the bibliography bibliography(style = "markdown",.bibstyle = "JSS", ordering = c("authors", "year", "title", "journal", "volume", "number", "pages", "doi", "url"), sort = FALSE, bibtex = get("bibtex_data", envir = knitcitations_options),...) style ordering formatting style to print bibliography (default is plain text). Can be text, bibtex, html, textversion, R, citation, or other formats defined forthe print bibentry class, see?print.bibentry for details. a character list of the order in which information should be printed (e.g. c("author", "year", "title", "journal", "volume", "number", "pages", "doi", "uri")) see details. Works only for rdfa and markdown formats at the moment. Other styles are formatted according to the bibstyle method, see for more information.

4 cite sort bibtex.bibstyle logical indicating if bibliography should be sorted alphabetically, defaults to FALSE logical, use bibtex data structure internally? (internal option only) the bibstyle function call or string. Defaults to journal of statistical software (JSS). See bibstyle.... additional arguments passed to print.bibentry, see bibentry The markdown and rdfa print formats can take the argument ordering. A character string provides the order in which elements should be returned. Elements not specified are omitted from the return entirely. Even if both DOI or URI (usually the URL) are given, method will return the URL only if the DOI is absent/unavailable. a list of bibentries, providing a bibliography of what s been cited Examples citet(citation("knitr")) bibliography() ## use markdown formatting, show only author, year, and url bibliography("markdown", ordering = c("authors", "year", "url")) ## Repeat citations do not create duplicates: bib <- c(citation("knitr"), citation("knitr"), citation("bibtex"), citation("bibtex"), citation("knitr"), citat citep(bib) bibliography() cite Add a citation (internal for citet and citep) Add a citation (internal for citet and citep) cite(x, bibtex = get("bibtex_data", envir = knitcitations_options), format_inline_fn = format_authoryear_p)

citep 5 x a doi or list of dois, or a bibentry (or list of bibentries) bibtex internal logical indicating if we use a cache or external bibtex file format_inline_fn a function which will create the inline citation format (stored with the entry to avoid non-unique citation styles, e.g. Boettiger 2012a, Boettiger 2012b.) Stores the full citation in a "works_cited" list, which can be printed with bibliography a parenthetical inline citation Examples citep("10.3998/3336451.0009.101") citep Add a paranthetical citation Add a paranthetical citation x citep(x,..., format_inline_fn = format_authoryear_p, inline_format = authoryear_p) a doi or list of dois, or a bibentry (or list of bibentries) inline_format a function for formating the inline citation, defaults to authoryear_t format_inline_fn function to format a single inline citation... additional arguments passed to citet, see citet for details Stores the full citation in a "works_cited" list, which can be printed with bibliography A variety of reasons for the citation can be provided following the CiTO ontology: c("cites","citesasauthority", "citesasmetadatadocument", "citesassourcedocument","citesforinformation", "iscitedby","obtainsbackgroundfrom", "sharesauthorswith", "usesdatafrom", "usesmethodin", "confirms", "credits", "extends", "obtainssupportfrom", "supports", "updates", "corrects", "critiques", "disagreeswith", "qualifies", "refutes", "discusses", "reviews")

6 citet a parenthetical inline citation Examples library(knitcitations) citep("10.3998/3336451.0009.101") ## Read in the bibtex information for some packages: knitr <- citation("knitr") knitcitations <- citation("knitcitations") # generate the parentetical citation for these: citep(list(knitr,knitcitations)) # generate the full bibliography: bibliography() ## Assign a citation key to a doi and then use it later: citep(c(halpern2006="10.1111/j.1461-0248.2005.00827.x")) citep("halpern2006") citet Add a textual citation Parameters listed here are the same for parenthetical citation, citep. x cito citet(x, cito = NULL, tooltip = get("tooltip", envir = knitcitations_options), linked = get("linked", envir = knitcitations_options), numerical = get("numerical", envir = knitcitations_options), format_inline_fn = format_authoryear_t, inline_format = authoryear_t) tooltip linked a doi or list of dois, or a bibentry (or list of bibentries) Semantic reason for the citation. Only active if linked=true Show a citation information on mouseover. Requires the tooltip javascript from http://twitter.github.com/bootstrap Pass logical TRUE/FALSE or set default behavior with cite_options link the inline citation text to the resource by doi (if available) or url? Pass logical TRUE/FALSE or set default behavior with cite_options numerical use citation instead of author-year format? (Not functional yet!) Pass logical TRUE/FALSE or set default behavior with cite_options format_inline_fn function to format a single inline citation

cite_options 7 inline_format a function for formating the inline citation, defaults to authoryear_t (designed for internal use only) Stores the full citation in a "works_cited" list, which can be printed with bibliography. A variety of reasons for the citation can be provided following the CiTO ontology: c("cites","citesasauthority", "citesasmetadatadocument", "citesassourcedocument","citesforinformation", "iscitedby","obtainsbackgroundfrom", "sharesauthorswith", "usesdatafrom", "usesmethodin", "confirms", "credits", "extends", "obtainssupportfrom", "supports", "updates", "corrects", "critiques", "disagreeswith", "qualifies", "refutes", "discusses", "reviews") a text inline citation Examples library(knitcitations) citet("10.3998/3336451.0009.101") ## Read in the bibtex information for some packages: knitr <- citation("knitr") citet(knitr) # generate the full bibliography: bibliography() ## Assign a citation key to a doi and then use it later: citet(c(halpern2006="10.1111/j.1461-0248.2005.00827.x")) citet("halpern2006") cite_options Toggles for various citation options Toggles for various citation options cite_options(tooltip = FALSE, linked = TRUE, numerical = FALSE, bibtex_data = FALSE) tooltip linked numerical bibtex_data Provide a javascript tooltip over the in-line citation? (requires twitter-bootstrap tooltip JS, see details). Add an HTML link around the in-line citation? Use numerical instead of author-year format citations? whether we should write to a bibtex file instead of the knitcitationscache environment for tracking bibliographic information of what we have already cited.

8 format_authoryear_p updates the option specified for the duration of the session. cleanbib Erase existing list of works cited Erase existing list of works cited cleanbib(bibtex = get("bibtex_data", envir = knitcitations_options)) bibtex logical, internal use parameter only. simply overwrites knitcitations.bib in bibtex data logging mode. (which means bibtex is used for internal data; not that the input data comes from bibtex. Input data can come from any source, bibtex or DOI, as shown in the documentation). format_authoryear_p format the author and year parenthetically This formats a single entry, though adjusted by author. This function is passed down to cite by citep, wher it creates the actuall formatting on the first use. format_authoryear_p(entry, char = "") entry char a bibentry a character to append to the citation (to disambiguate). This is handled automatically by the cite function. the author-year citation

format_authoryear_t 9 format_authoryear_t format the author and year This formats a single entry, though adjusted by author. This function is passed down to cite by citet, wher it creates the actuall formatting on the first use. format_authoryear_t(entry, char = "") entry char a bibentry a character to append to the citation (to disambiguate). This is handled automatically by the cite function. the author-year citation functiontable a table of functions in a package This function takes a package name an generates a two-column table with the names of each function in the package and the short description from the help documentation. pkg functiontable(pkg,...) a string specifying the name of a package,... additional arguments to xtable useful for Sweave/knit manuals specifying a table of functions Note that xtable format can also be set with options(xtable.type="latex") or options(xtable.type="html"). This function modified from DWin s solution on StackOverflow.com, http://stackoverflow.com/questions/7326808/gettingthe-list-of-functions-in-an-r-package-to-be-used-in-latex

10 newbib the output of xtable (as html, or specify type="latex") Examples functiontable("xtable") greycite greycite citation method Grab citation data using the greycite API greycite(url, format = c("bib", "json")) url format the website URL have greycite return data in bib (bibtex) or json format? a bibentry class object newbib Erase existing list of works cited Erase existing list of works cited newbib(bibtex = get("bibtex_data", envir = knitcitations_options)) bibtex logical, internal use parameter only. simply overwrites knitcitations.bib in bibtex data logging mode. (which means bibtex is used for internal data; not that the input data comes from bibtex. Input data can come from any source, bibtex or DOI, as shown in the documentation).

numeral 11 numeral Formatting for numeric inline citations. Needs testing. Formatting for numeric inline citations. Needs testing. numeral(entry) entry a bibentry object, e.g. from cite read.bibtex read in bibtex and use key as list names read in bibtex and use key as list names read.bibtex(bibfile) bibfile a bibtex.bib file this differs from read.bib in that the list is named. this allows one to use citep(bib[c("key1", "key2")] a list of citation information See Also read.bib citep citet

12 write.bibtex ref Lookup article info via CrossRef with DOI. Lookup article info via CrossRef with DOI. doi ref(doi, title = FALSE, url = "http://www.crossref.org/openurl/", key = "cboettig@gmail.com",..., curl = getcurlhandle()) title url key digital object identifier for an article in PLoS Journals return the title of the paper or not (defaults to FALSE) the PLoS API url for the function (should be left to default) your PLoS API key, either enter, or loads from.rprofile... optional additional curl options (debugging tools mostly) curl If using in a loop, call getcurlhandle() first and pass the returned value in here (avoids unnecessary footprint) Metadata from DOI in R s bibentry format. Examples ref("10.3998/3336451.0009.101") print(ref("10.3998/3336451.0009.101"), style="bibtex") print(ref("10.3998/3336451.0009.101"), style="text") write.bibtex write a bibtex file write a bibtex file write.bibtex(entry, file = "knitcitations.bib", append = FALSE, verbose = TRUE, create_key = TRUE)

write_cache 13 entry file append verbose create_key a bibentry object, list of bibentry objects, or a character vector of package names output bibtex file. Will automatically append.bib if not added. if NULL will use stdout. a logical indicating that bibtex entries be added the the file. If FALSE (default), the file is overwritten. a logical to toggle verbosity. If file=null, verbosity is forced off. logical indicating whether function should create a bibtex citation key if the object doesn t have one. a list of citation information, invisibly The knitcitations package automatically extends the use of this function to be able to write bibtex files from a string of DOIs, making it valuable for purposes beyond the citation of packages. See Also read.bib citep citet Examples write.bibtex(c("yihui2013" = citation("knitr"), "Boettiger2013" = citation("knitcitations"), "TempleLang2012"=c bib <- read.bibtex("knitcitations.bib") write_cache write knitcitations data to a cache object instead of a file write knitcitations data to a cache object instead of a file write_cache(a_bibentry, bibtex = get("bibtex_data", envir = knitcitations_options)) a_bibentry bibtex a bibentry object, possibly already named with a key logical, use a bibtex file for the cache of cited works rather than an environment? writes the bibentry to the environment knitcitationscache, created by

Index authoryear_p, 2 authoryear_t, 3 bibentry, 4 bibliography, 3, 5, 7 bibstyle, 3, 4 cite, 4 cite_options, 6, 7 citep, 5, 6 citet, 5, 6 cleanbib, 8 format_authoryear_p, 8 format_authoryear_t, 9 functiontable, 9 greycite, 10 newbib, 10 numeral, 11 read.bibtex, 11 ref, 12 write.bibtex, 12 write_cache, 13 14