-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME.Rmd
65 lines (45 loc) · 2.41 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>",
fig.path = "man/figures/README-",
out.width = "100%"
)
```
# Ranystyle <img src="man/figures/logo.png" align="right" alt="" width="120" />
<!-- badges: start -->
[![Lifecycle: experimental](https://img.shields.io/badge/lifecycle-experimental-orange.svg)](https://lifecycle.r-lib.org/articles/stages.html#experimental)
<!-- badges: end -->
Ranystyle (pronounce R-anystyle) is an R package designed to automate the **extraction**, **parsing**, and **cleaning** of **bibliographic references** from PDF and text documents as well as vector of references stored in an R object. Utilizing the power of the 'anystyle' Ruby gem, it segments references and converts them into structured formats suitable for analysis and use.
You can cite this package as:
```{r}
citation("Ranystyle")
```
## Installation
You can install the development version of Ranystyle from [GitHub](https://github.com/) with:
```r
# install.packages("devtools")
devtools::install_github("agoutsmedt/Ranystyle")
```
For the functions of *Ranystyle* to work, you need to install manually [Ruby](https://www.ruby-lang.org/fr/downloads/) and [RubyGems](https://rubygems.org/pages/download?locale=fr) first. Then, you can use `install_anystyle()` to
automatically install `anystyle` and `anystyle-cli` ruby gems.
## Example
Here's a basic example of how you might use Ranystyle to parse and clean references from a PDF document:
```{r example}
library(Ranystyle)
# Path to your PDF document
pdf_path <- system.file("extdata", package = "Ranystyle")
files <- list.files(pdf_path)
# Extract references from the PDF
extracted_refs <- find_ref_to_df(input = paste0(pdf_path, "/", files[1]))
# Print the extracted references
print(extracted_refs)
```
See the `vignette("using_Ranystyle")` for a more in-depth presentation of the package.
## Credits
*anystyle* has been developed by [Alex Fenton](https://github.com/a-fent), [Sylvester Keil](https://github.com/inukshuk), [Johannes Krtek](https://github.com/flachware) and [Ilja Srna](https://github.com/namyra). *anystyle* is under copyright: Copyright 2011-2018 Sylvester Keil. All rights reserved. See the [Licence](https://github.com/inukshuk/anystyle-cli/blob/master/LICENSE) for details.
The logo of *Ranystyle* has been generated with DALL·E.