Learn R Programming

animint (version 2017.01.04)

run_servr: Spawn a child R session that runs a 'blocking' command

Description

Run a blocking command in a child R session (for example a file server or shiny app)

Usage

run_servr(directory = ".", port = 4848,
  code = "servr::httd(dir='%s', port=%d)")

Arguments

directory

path that the server should map to.

port

port number to _attempt_ to run server on.

code

R code to execute in a child session

Value

port number of the successful attempt