Moving Data from Birst to R

In addition to pulling data from R into Birst, you can move data from Birst to R. Birstprovides two mechanisms to do this:

As an manual, ad-hoc movement of data. For example, for one-time data analysis.

Automated movement to R as part of an ETL script.

To manually move the results of a Birst report to the R Server

1. Navigate to the Export Report Data page under the Manage Access tab in the Admin module.
2. When an R Server is configured you see an extra option that allows you to export to a path on the R Server.

3. Specify the report to export and the path, then click Export. Reports will be exported in a pipe (‘|’) delimited fashion.

To automatically move Birst data to the R Server using RWRITE

Birst provides the BQL command RWRITE for this purpose. See Creating a Scripted (ETL) Data Source for information on creating a script in Birst.

RWRITE has two parameters, the first being the path to write to on the R Server, and the second being the value to write.

A file is created during script execution the first time a path is referenced. That same connection is used until the end of the script. This way, data can be written to the R file with precise control.

The image below illustrates how to take the iris data source as a source and write columns back to file on the R Server.