komaletter

R package for comfortable writing of beautiful PDF letters in Markdown.

https://github.com/rnuske/komaletter

Science Score: 36.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
  • DOI references
    Found 3 DOI reference(s) in README
  • Academic publication links
    Links to: zenodo.org
  • Committers with academic emails
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (14.2%) to scientific vocabulary

Keywords

koma-script latex letter markdown pandoc pandoc-letter pdf r r-package

Keywords from Contributors

geo
Last synced: 6 months ago · JSON representation

Repository

R package for comfortable writing of beautiful PDF letters in Markdown.

Basic Info
Statistics
  • Stars: 88
  • Watchers: 3
  • Forks: 21
  • Open Issues: 2
  • Releases: 8
Topics
koma-script latex letter markdown pandoc pandoc-letter pdf r r-package
Created almost 8 years ago · Last pushed over 1 year ago
Metadata Files
Readme Changelog

README.md

komaletter: Simply Beautiful PDF Letters from Markdown

R-CMD-check Package-License CRAN Dependencies DOI <!-- badges: end -->

Motivation

Simple letters tend to look very much alike. They are either determined by a standard eg. window envelope style or writer's preferences. Since the layout is fixed, letters can be written perfectly in R Markdown.

The KOMA-Script LaTeX Bundle provides layouts for many common window envelope types (German, US, French, Japanese, ...) and the possibility to define your own layout. The komaletter package also provides it's own default letter layout loosely based on DIN 5008B.

This package is an adaptation of the linl package for international writers. linl itself is based on the pandoc-letter template and extends it for use from R via the rmarkdown package.

Examples

Skeleton

The skeleton provided by komaletter creates a very simple letter as a starting point for your own writing. Several formatting defaults such as font, fontsize, indentation are in use. See vignette('intro', 'komaletter') and help(komaletter) for a complete list and their default values. The following figure shows the rmarkdown source on the left and the rendered pdf on the right.

Vignette

The vignette examples are a bit more detailed and s demonstrate, for example, how to include a signature, choose a different layout and make some format settings. All of these are driven by simple settings in the YAML header as shown in the following figure on the left.

Usage

To start a new letter you can take advantage of the komaletter skeleton via rmarkdown::draft() or the RStudio menu: File > New File > R Markdown... > From Template > komaletter (PDF). When finished writing your letter the RMarkdown document can be rendered to PDF via rmarkdown::render() or the RStudio Knit button.

```r

start a new letter using the provided skeleton

rmarkdown::draft("my_letter.Rmd", template="pdf", package="komaletter", edit=FALSE)

change my_letter.Rmd to your liking

turn Rmd into a beautiful PDF

rmarkdown::render("my_letter.Rmd") ```

About Printing

Some PDF viewers do not realize that the document already has a blank margin and scale or 'fit to page' for printing. This generally results in smaller fonts, overly large margins, broken layout and most importantly a misplaced address. In the worst case, parts of the address are not visible in the window of the envelope.

komaletter's default layout signals the PDF viewer to print the document at its actual size. Unfortunately, not many PDF viewers heed this hint.

Thus, before printing the document, you should check that the document is not shrunk or 'fit to page'. The document must be printed at its actual size / 100% so that the positions of the elements are correct.

Installation

You can install the released version of komaletter from CRAN with

r install.packages("komaletter")

and the development version from GitHub using the package remotes

r remotes::install_github("rnuske/komaletter")

Requirements

Beyond the R package dependency rmarkdown, a working pandoc binary and a LaTeX distribution including KOMA-Script is needed. RStudio installs it's own copy of pandoc, otherwise do what is needed on your OS. As for LaTeX look for texlive which is included in most Linux distributions. KOMA-Script is part of all but the most bare bone LaTeX distributions. Something like sudo apt install pandoc pandoc-citeproc texlive should provide everything needed on Debian/Ubuntu. To get a working LaTeX on Windows it is recommended to use the service of the R package tinytex.

If you plan to write non-english letters, make sure you have the necessary language packs, i.e. texlive-lang-german.

Authors

Robert Nuske, Dirk Eddelbuettel and Aaron Wolen.

License

GPL-3 for this package, the work in pandoc-letter, as well as the underlying Pandoc template.

Owner

  • Name: Robert Nuske
  • Login: rnuske
  • Kind: user
  • Company: privat hier

GitHub Events

Total
  • Watch event: 1
Last Year
  • Watch event: 1

Committers

Last synced: 11 months ago

All Time
  • Total Commits: 110
  • Total Committers: 4
  • Avg Commits per committer: 27.5
  • Development Distribution Score (DDS): 0.1
Past Year
  • Commits: 1
  • Committers: 1
  • Avg Commits per committer: 1.0
  • Development Distribution Score (DDS): 0.0
Top Committers
Name Email Commits
Robert Nuske r****e@n****e 99
Robert Nuske r****e@m****g 9
Shaurita m****s@g****m 1
Christophe Dervieux c****x@g****m 1
Committer Domains (Top 20 + Academic)

Issues and Pull Requests

Last synced: 6 months ago

All Time
  • Total issues: 16
  • Total pull requests: 5
  • Average time to close issues: 3 months
  • Average time to close pull requests: 4 days
  • Total issue authors: 13
  • Total pull request authors: 4
  • Average comments per issue: 3.88
  • Average comments per pull request: 2.2
  • Merged pull requests: 4
  • Bot issues: 0
  • Bot pull requests: 0
Past Year
  • Issues: 0
  • Pull requests: 0
  • Average time to close issues: N/A
  • Average time to close pull requests: N/A
  • Issue authors: 0
  • Pull request authors: 0
  • Average comments per issue: 0
  • Average comments per pull request: 0
  • Merged pull requests: 0
  • Bot issues: 0
  • Bot pull requests: 0
Top Authors
Issue Authors
  • rnuske (3)
  • michielvandijk (2)
  • fkohrt (1)
  • jooyoungseo (1)
  • pschmidtwalter (1)
  • Hanomics (1)
  • mm28ajos (1)
  • LuisLauM (1)
  • bnicenboim (1)
  • jrennstich (1)
  • njbart (1)
  • davidbaniadam (1)
  • fergusjchadwick (1)
Pull Request Authors
  • rnuske (2)
  • MartinSchobben (1)
  • sdhutchins (1)
  • cderv (1)
Top Labels
Issue Labels
Pull Request Labels

Packages

  • Total packages: 1
  • Total downloads:
    • cran 319 last-month
  • Total dependent packages: 0
  • Total dependent repositories: 0
  • Total versions: 8
  • Total maintainers: 1
cran.r-project.org: komaletter

Simply Beautiful PDF Letters from Markdown

  • Versions: 8
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 319 Last month
Rankings
Forks count: 3.7%
Stargazers count: 4.6%
Average: 19.1%
Downloads: 21.8%
Dependent packages count: 29.8%
Dependent repos count: 35.5%
Maintainers (1)
Last synced: 6 months ago

Dependencies

DESCRIPTION cran
  • R >= 3.0 depends
  • rmarkdown >= 0.6 imports
  • knitr >= 1.8 suggests