-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
69 changed files
with
1,740 additions
and
592 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,3 +4,4 @@ | |
paper.md | ||
paper.bib | ||
COPYRIGHT.md | ||
^.github |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Describe the bug** | ||
A clear and concise description of what the bug is. | ||
|
||
**To Reproduce** | ||
Steps to reproduce the behavior: | ||
1. Go to '...' | ||
2. Click on '....' | ||
3. Scroll down to '....' | ||
4. See error | ||
|
||
**Expected behavior** | ||
A clear and concise description of what you expected to happen. | ||
|
||
**Screenshots** | ||
If applicable, add screenshots to help explain your problem. | ||
|
||
**Desktop (please complete the following information):** | ||
- OS: [e.g. iOS] | ||
- Browser [e.g. chrome, safari] | ||
- Version [e.g. 22] | ||
|
||
**Smartphone (please complete the following information):** | ||
- Device: [e.g. iPhone6] | ||
- OS: [e.g. iOS8.1] | ||
- Browser [e.g. stock browser, safari] | ||
- Version [e.g. 22] | ||
|
||
**Additional context** | ||
Add any other context about the problem here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project | ||
title: '' | ||
labels: '' | ||
assignees: '' | ||
|
||
--- | ||
|
||
**Is your feature request related to a problem? Please describe.** | ||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] | ||
|
||
**Describe the solution you'd like** | ||
A clear and concise description of what you want to happen. | ||
|
||
**Describe alternatives you've considered** | ||
A clear and concise description of any alternative solutions or features you've considered. | ||
|
||
**Additional context** | ||
Add any other context or screenshots about the feature request here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,15 @@ | ||
language: r | ||
sudo: required | ||
|
||
# System dependencies for building | ||
r_binary_packages: | ||
r: | ||
- oldrel | ||
- release | ||
- devel | ||
|
||
r_packages: | ||
- BH | ||
- Rcpp | ||
- testthat | ||
|
||
r_github_packages: | ||
- jimhester/covr | ||
- covr | ||
|
||
after_success: | ||
- Rscript -e 'covr::coveralls()' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,103 +1,19 @@ | ||
# Generated by using Rcpp::compileAttributes() -> do not edit by hand | ||
# Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393 | ||
|
||
#' @rdname metaphone | ||
#' @name metaphone | ||
#' @title Generate phonetic versions of strings with Metaphone | ||
#' | ||
#' @description | ||
#' The function \code{metaphone} phonentically encodes the | ||
#' given string using the metaphone algorithm. | ||
#' | ||
#' @param word string or vector of strings to encode | ||
#' @param maxCodeLen maximum length of the resulting encodings, in characters | ||
#' | ||
#' @details There is some discrepency | ||
#' with respect to how the metaphone algorithm actually works. For | ||
#' instance, there is a version in the Java Apache Commons library. | ||
#' There is a version provided within PHP. These do not provide the same | ||
#' results. On the questionable theory that the implementation in PHP | ||
#' is probably more well known, this code should match it in output. | ||
#' | ||
#' This implementation is based on a Javascript implementation which is | ||
#' itself based on the PHP internal implementation. | ||
#' | ||
#' The variable \code{maxCodeLen} is the limit on how long the returned | ||
#' metaphone should be. | ||
#' | ||
#' @return a character vector containing the metaphones of \code{word}, | ||
#' or an NA if the \code{word} value is NA | ||
#' | ||
#' @section Caveats: | ||
#' The \code{metaphone} algorithm is only | ||
#' defined for inputs over the standard English alphabet, \emph{i.e.}, | ||
#' "A-Z." For inputs outside this range, the output is undefined. | ||
#' | ||
#' @family phonics | ||
#' | ||
#' @examples | ||
#' metaphone("wheel") | ||
#' metaphone(c("school", "benji")) | ||
#' | ||
#' @useDynLib phonics | ||
#' @importFrom Rcpp evalCpp | ||
#' @export | ||
metaphone <- function(word, maxCodeLen = 10L) { | ||
.Call('_phonics_metaphone', PACKAGE = 'phonics', word, maxCodeLen) | ||
metaphone_internal <- function(word, maxCodeLen = 10L) { | ||
.Call('_phonics_metaphone_internal', PACKAGE = 'phonics', word, maxCodeLen) | ||
} | ||
|
||
#' @rdname soundex | ||
#' @name soundex | ||
#' @title Soundex | ||
#' | ||
#' @description | ||
#' The Soundex phonetic algorithms | ||
#' | ||
#' @param word string or vector of strings to encode | ||
#' @param maxCodeLen maximum length of the resulting encodings, in characters | ||
#' | ||
#' @details The function \code{soundex} phonentically encodes the given | ||
#' string using the soundex algorithm. The function \code{refinedSoundex} | ||
#' uses Apache's refined soundex algorithm. Both implementations are loosely | ||
#' based on the Apache Commons Java editons. | ||
#' | ||
#' The variable \code{maxCodeLen} is the limit on how long the returned | ||
#' soundex should be. | ||
#' | ||
#' @return soundex encoded character vector | ||
#' | ||
#' @section Caveats: | ||
#' The \code{soundex} and \code{refinedSoundex} algorithms are only | ||
#' defined for inputs over the standard English alphabet, \emph{i.e.}, | ||
#' "A-Z." For inputs outside this range, the output is undefined. | ||
#' | ||
#' @references | ||
#' Charles P. Bourne and Donald F. Ford, "A study of methods for | ||
#' systematically abbreviating English words and names," \emph{Journal | ||
#' of the ACM}, vol. 8, no. 4 (1961), p. 538-552. | ||
#' | ||
#' Howard B. Newcombe, James M. Kennedy, "Record linkage: making | ||
#' maximum use of the discriminating power of identifying information," | ||
#' \emph{Communications of the ACM}, vol. 5, no. 11 (1962), p. 563-566. | ||
#' | ||
#' @family phonics | ||
#' | ||
#' @examples | ||
#' soundex("wheel") | ||
#' soundex(c("school", "benji")) | ||
#' | ||
#' @useDynLib phonics | ||
#' @importFrom Rcpp evalCpp | ||
#' @export | ||
soundex <- function(word, maxCodeLen = 4L) { | ||
.Call('_phonics_soundex', PACKAGE = 'phonics', word, maxCodeLen) | ||
soundex_internal <- function(word, maxCodeLen = 4L) { | ||
.Call('_phonics_soundex_internal', PACKAGE = 'phonics', word, maxCodeLen) | ||
} | ||
|
||
#' @rdname soundex | ||
#' @useDynLib phonics | ||
#' @importFrom Rcpp evalCpp | ||
#' @export | ||
refinedSoundex <- function(word, maxCodeLen = 10L) { | ||
.Call('_phonics_refinedSoundex', PACKAGE = 'phonics', word, maxCodeLen) | ||
refinedSoundex_internal <- function(word, maxCodeLen = 10L) { | ||
.Call('_phonics_refinedSoundex_internal', PACKAGE = 'phonics', word, maxCodeLen) | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.