https://github.com/mrcsparker/rcrawlback
Playtime with R callbacks
https://github.com/mrcsparker/rcrawlback
Last synced: 2 months ago
JSON representation
Playtime with R callbacks
- Host: GitHub
- URL: https://github.com/mrcsparker/rcrawlback
- Owner: mrcsparker
- License: gpl-3.0
- Created: 2015-10-08T19:24:34.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-10-11T06:00:51.000Z (over 9 years ago)
- Last Synced: 2025-02-14T02:22:29.611Z (4 months ago)
- Language: C++
- Size: 152 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# crawlback
Playtime with R callbacks
Testing passing Rcpp Functions with C function pointers
```R
do_start <- function() {
print("starting")
}do_run <- function() {
print("running")
}do_end <- function() {
print("ending")
}print("running callbacks")
x <- RCrawlback$new()
x$add_start_callback(do_start)
x$add_run_callback(do_run)
x$add_end_callback(do_end)
x$run()## Prints:
# [1] "starting"
# [1] "running"
# [1] "ending"```