All Projects → eddelbuettel → rcppfastfloat

eddelbuettel / rcppfastfloat

Licence: other
Rcpp Bindings for the 'fastfloat' Header-Only Library

Programming Languages

C++
36643 projects - #6 most used programming language
r
7636 projects

Projects that are alternatives of or similar to rcppfastfloat

rcppgsl
Rcpp integration for GNU GSL vectors and matrices
Stars: ✭ 28 (+55.56%)
Mutual labels:  cran, rcpp, r-package
inline
Inline C, C++ or Fortran functions in R
Stars: ✭ 33 (+83.33%)
Mutual labels:  cran, rcpp, r-package
rdomains
Classifying the content of domains
Stars: ✭ 47 (+161.11%)
Mutual labels:  cran, r-package
rcppsimdjson
Rcpp Bindings for the 'simdjson' Header Library
Stars: ✭ 103 (+472.22%)
Mutual labels:  cran, r-package
RcppEigen
Rcpp integration for the Eigen templated linear algebra library
Stars: ✭ 89 (+394.44%)
Mutual labels:  cran, r-package
thinkr
Some tools for cleaning up messy 'Excel' files to be suitable for R
Stars: ✭ 21 (+16.67%)
Mutual labels:  cran, r-package
Tint
Tint is not Tufte
Stars: ✭ 226 (+1155.56%)
Mutual labels:  cran, r-package
oem
Penalized least squares estimation using the Orthogonalizing EM (OEM) algorithm
Stars: ✭ 22 (+22.22%)
Mutual labels:  cran, r-package
Webservices
CRAN WebTechnologies Task View
Stars: ✭ 160 (+788.89%)
Mutual labels:  cran, r-package
eia
An R package wrapping the US Energy Information Administration open data API.
Stars: ✭ 38 (+111.11%)
Mutual labels:  cran, r-package
rcppcnpy
Rcpp bindings for NumPy files
Stars: ✭ 24 (+33.33%)
Mutual labels:  cran, r-package
vosonSML
R package for collecting social media data and creating networks for analysis.
Stars: ✭ 65 (+261.11%)
Mutual labels:  cran, r-package
Pacman
A package management tools for R
Stars: ✭ 220 (+1122.22%)
Mutual labels:  cran, r-package
Arsenal
An Arsenal of 'R' Functions for Large-Scale Statistical Summaries
Stars: ✭ 171 (+850%)
Mutual labels:  cran, r-package
Littler
A scripting and command-line front-end for GNU R
Stars: ✭ 238 (+1222.22%)
Mutual labels:  cran, r-package
Simmer
Discrete-Event Simulation for R
Stars: ✭ 170 (+844.44%)
Mutual labels:  cran, r-package
packagefinder
Comfortable search for R packages on CRAN, either directly from the R console or with an R Studio add-in
Stars: ✭ 43 (+138.89%)
Mutual labels:  cran, r-package
globals
🌐 R package: Identify Global Objects in R Expressions
Stars: ✭ 27 (+50%)
Mutual labels:  cran, r-package
Pinp
Pinp Is Not PNAS -- Two-Column PDF Template
Stars: ✭ 134 (+644.44%)
Mutual labels:  cran, r-package
Osrm
Shortest Paths and Travel Time from OpenStreetMap with R
Stars: ✭ 160 (+788.89%)
Mutual labels:  cran, r-package

RcppFastFloat: Rcpp Bindings for the fastfloat C++ Header-Only Library

CI License CRAN Dependencies Downloads Last Commit

Motivation

Converting ascii text into (floating-point) numeric values is a very common problem. The fast_float header-only C++ library by Daniel Lemire does this very well, and very fast at up to or over to 1 gigabyte per second as described in more detail in a recent arXiv paper.

This package brings this header-only library to R so that other R user can access it simply by adding LinkingTo: RcppFastFloat.

Example

A modified example function is included, try

library(RcppFastFloat)
exampleParse()

with default arguments---or supply some arguments. We also include a simple timing comparison in the file benchmark/comparison.R which you can run just call via Rscript or r. On our machine, fast_float comes out as just over 3 times as fast as the next best alternative (and this counts the function calls and all, so pure parsing speed is still a little bettter).

> source("comparison.R")
Unit: milliseconds
      expr      min       lq     mean   median       uq      max neval cld
     scanf 218.8936 224.1223 238.5650 227.1901 229.9116 1343.433   100   c
      atof 124.8087 127.3274 129.4104 128.5858 130.9138  146.334   100  b 
    strtod 124.5705 127.2157 129.1238 129.1042 130.7504  137.143   100  b 
      stod 127.1751 129.7343 131.7339 131.4854 133.1425  147.763   100  b 
 fastfloat  40.6219  41.3042  42.5729  42.3209  43.1738   57.788   100 a  
> 

Or in chart form:

Status

Right now the package is brand new and reasonably empty.

Contributing

Any problems, bug reports, or features requests for the package can be submitted and handled most conveniently as Github issues in the repository.

Before submitting pull requests, it is frequently preferable to first discuss need and scope in such an issue ticket. See the file Contributing.md (in the Rcpp repo) for a brief discussion.

Author

For the R package, Dirk Eddelbuettel and Brendan Knapp.

For everything pertaining to fast_float, Daniel Lemire (and contributors).

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].