All Projects → r-assist → Searcher

r-assist / Searcher

Query Search Portals from R

Programming Languages

r
7636 projects

Projects that are alternatives of or similar to Searcher

auto-async-wrap
automatic async middleware wrapper for expressjs errorhandler.
Stars: ✭ 21 (-64.41%)
Mutual labels:  error-handling, automatic
Panic Overlay
Displays JS errors in browsers. Shows sources. Use with any framework. 💥✨
Stars: ✭ 50 (-15.25%)
Mutual labels:  error-handling
Dbworld Search
🔍 简单的搜索引擎, django 框架
Stars: ✭ 39 (-33.9%)
Mutual labels:  search-engine
Klask Io
klask.io is an open source search engine for source code, live demo
Stars: ✭ 45 (-23.73%)
Mutual labels:  search-engine
Friendly Exception
An interface for an exception to be friendly
Stars: ✭ 41 (-30.51%)
Mutual labels:  error-handling
Rats Search
BitTorrent P2P multi-platform search engine for Desktop and Web servers with integrated torrent client.
Stars: ✭ 1,037 (+1657.63%)
Mutual labels:  search-engine
Auto Frontend
Automatically generate frontends for go programs
Stars: ✭ 37 (-37.29%)
Mutual labels:  automatic
Github
a module for building, searching, installing, managing, and mining Stata packages from GitHub
Stars: ✭ 56 (-5.08%)
Mutual labels:  search-engine
Bugsnag Node
[DEPRECATED] Please upgrade to our Universal JS notifier "@bugsnag/js" • https://github.com/bugsnag/bugsnag-js
Stars: ✭ 48 (-18.64%)
Mutual labels:  error-handling
Glue
⛓️ Bindings that stick. A simple and generic API for C++ to other language bindings supporting bidirectional communication, inheritance and automatic declarations.
Stars: ✭ 44 (-25.42%)
Mutual labels:  automatic
Github Awesome Autocomplete
Add instant search capabilities to GitHub's search bar
Stars: ✭ 1,015 (+1620.34%)
Mutual labels:  search-engine
Rollbar Android
Rollbar for Android
Stars: ✭ 41 (-30.51%)
Mutual labels:  error-handling
Progress Activity
Easily add loading, empty and error states in your app.
Stars: ✭ 1,039 (+1661.02%)
Mutual labels:  error-handling
Algolia Webcrawler
Simple node worker that crawls sitemaps in order to keep an algolia index up-to-date
Stars: ✭ 40 (-32.2%)
Mutual labels:  search-engine
Ios Auto Replace Package
iOS自动打包脚本,并实现图片素材、文字资源、部分代码的替换和重签名,基于python实现。
Stars: ✭ 50 (-15.25%)
Mutual labels:  automatic
Happy
the alchemist's happy path with elixir
Stars: ✭ 37 (-37.29%)
Mutual labels:  error-handling
Phinde
Self-hosted search engine for your static blog
Stars: ✭ 42 (-28.81%)
Mutual labels:  search-engine
Automatic Release
Automates the release process for GitHub projects.
Stars: ✭ 46 (-22.03%)
Mutual labels:  automatic
Manaflux
The app needs a rewrite. It might not work anymore. An assistant that can choose your runes, summoner spells, and item sets for League of Legends.
Stars: ✭ 57 (-3.39%)
Mutual labels:  automatic
Suggest
Top-k Approximate String Matching.
Stars: ✭ 50 (-15.25%)
Mutual labels:  search-engine

searcher

R build status CRAN RStudio mirror downloads CRAN_Status_Badge Codecov test coverage

The goal of searcher is to provide a search interface directly inside of R. For example, to look up rcpp example numeric vector or ggplot2 fix axis labels call one of the search_*() functions to automatically have a web browser open, go to a search site, and type the query. By default, the search functions will attempt to search the last error on call if no query is specified.

Installation

The searcher package is available on both CRAN and GitHub. The CRAN version is considered stable while the GitHub version is in a state of development and may break.

You can install the stable version of the searcher package with:

install.packages("searcher")

For the development version, you can opt for:

if(!requireNamespace("remotes")) { install.packages("remotes") }
remotes::install_github("r-assist/searcher")

Usage

library(searcher)

Search Terms

The search_*() functions can be used to search a query directly from R on major search engines, programming help websites, and code repositories. The following search platforms are supported: Google, Bing, DuckDuckGo, Startpage, Ecosia, Twitter, StackOverflow, RStudio Community, GitHub, and BitBucket. By default, an appropriate suffix for each platform that ensures relevant results to R is appended to all queries. This behavior can be disabled by using rlang = FALSE.

# Searching R project on major search engines
search_google("R project")
search_bing("R project")
search_ecosia("R project")
search_duckduckgo("R project")                           # or search_ddg(...)
search_startpage("R project")                            # or search_sp(...)

# Searching Twitter to find out about machine learning for R and in general
search_twitter("machine learning")
search_twitter("machine learning", rlang = FALSE)

# Searching for linear regression questions for R and in general
search_stackoverflow("linear regression")
search_stackoverflow("linear regression", rlang = FALSE) # or search_so(...)

# Searching RStudio Community for tips
search_rstudio_community("tips")
search_rstudio_community("tips", rlang = FALSE)          # or search_rscom(...)

# Searching GitHub Issues for maps in R and other languages
search_github("maps")
search_github("maps", rlang = FALSE)                     # or search_gh(...)

# Searching BitBucket for assertions in R and other languages
search_bitbucket("assertions")
search_bitbucket("assertions", rlang = FALSE)            # or search_bb(...)

Search Errors

searcher offers preliminary support for automatically or manually searching errors that are generated in R. For more robust error search support and to also search warning messages, please use the errorist package.

Automatically

Searching the last error automatically is possible by registering a function as R’s error handler via either searcher(site="") or one of the search_*() functions. Thus, when an error occurs, this function will automatically be called. This triggers a new browser window to open with the error term listed in verbatim.

# Using the generic search error handler
options(error = searcher("google"))

# Directly specify the search function
options(error = search_github)
options(error = search_google)

Manually

Alternatively, these functions can also be used manually so that the default error dispatch is preserved. In the manual case, you will have to explicitly call the search function. After that, a browser window will open with the last error message as the search query on the desired search portal.

search_google()
search_bing()
search_ecosia()
search_twitter()
search_duckduckgo()        # or search_ddg()
search_startpage()         # or search_sp()
search_stackoverflow()     # or search_so()
search_rstudio_community() # or search_rscom()
search_github()            # or search_gh()
search_bitbucket()         # or search_bb()

Package Customizations

The ability to customize different operations in searcher is possible by setting values in options() within ~/.Rprofile. Presently, the following options are available:

  • searcher.launch_delay: Amount of time between launching the web browser from when the command was issued. Default is 0.5 seconds.
  • searcher.use_rstudio_viewer: Display search results in the RStudio viewer pane instead of a web browser. Default is FALSE.
  • searcher.default_keyword: Suffix keyword to focus search results between either "base" or "tidyverse". Default is "base".

To set one of these options, please create the .Rprofile by typing into R:

file.edit("~/.Rprofile")

From there, add:

.First = function() {
  options(
    searcher.launch_delay       = 0,
    searcher.use_rstudio_viewer = FALSE,
    searcher.default_keyword    = "tidyverse"
    ## Additional options.
  )
}

Motivation

The idea for searcher began as a project to automatically search errors and warnings that occurred while working with R after a conversation among Dirk Eddelbuettel, Barry Rowlingson, and myself. However, there was no search interface that allowed querying directly from R outside of the built-in utils::RSiteSearch(), which only queries http://search.r-project.org/, and the sos package, which queries an off-site user premade database. Both of these options were focused solely on querying R documentation made available by packages. Given the nature of errors generally being undocumented, neither of these approaches could be used. Thus, searcher was unintentionally born to provide a means for errorist, which contains a robust way to automatically searching errors and warnings.

Special Thanks

Publicity

On the #rstats-twitter verse, searcher has been positively received by community members.

R package “searcher” that automatically searches Stackoverflow for error that you just saw in the console. Cool package, especially for those who learn R :) https://github.com/coatless/searcher … #r #rlang #rstats #rstudio

Paweł Przytuła March 23th, 2019. ~292 Retweets and 876 likes

Did you know, using “searcher” package, you could automatically to search stackoverflow, google, GitHub and many more sites for errors, packages or topics. #rstats

Shakirah Nakalungi June 29th, 2019, when she was Rotating Curator for the “We are R-Ladies” twitter account. ~144 Retweets and 544 likes

Please let us know via an issue ticket about how you are using searcher.

License

GPL (>= 2)

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].