Chapter 1. Introduction

Table of Contents

What is Rax?

Welcome to the Rax v1.3 Reference Manual. This manual describes the Rax computer language and its usage.

What is Rax?

Rax is a scripting language designed to work with large sets of behavioral data. Behavioral data describe subjects that perform actions. For example, people that buy books from a website or trams that consume electric power. Behavioral data are used to analyze, compare, and predict behavior.

Rax is based on relational algebra which is a theoretical foundation for relational databases. In Rax, data are modeled as sets and sets of tuples and processed using classical set operators (such as union or intersection) and relational operators (such as selection, projection and aggregation). On top of that, Rax has advanced system of temporal types and operators, which make Rax very suitable for analyzing behavioral data which typically contain a time component.

Rax is a functional language which means that Rax programs are executed by evaluating mathematical functions and that there are no global variables (so-called global state) that can change. In computer-science speak, we say that Rax functions and expressions do not have side effects. That makes Rax scripts easy to understand and reason about.

Rax is an interpreted language, which means that you need a Rax interpreter to execute Rax scripts. You can also run Rax interpreter in interactive mode, which means that you can type your analysis statement by statement and look at intermediate results. Rax interpreter runs atop an SQL-based relational database system. That means that Rax interpreter stores datasets in an SQL database and translates operations on these datasets into SQL queries. Rax can also operate on tables that already reside in the database. As such, Rax interpreter can be seen as an add-on to your SQL database[1]. It is also very easy to export results produced by Rax back to the SQL database or to an Excel file. Therefore, Rax can be seen more as an enhancement to your current data-processing environment than as its replacement, which makes Rax adoption easy.

Rax interpreter can run on top of many different database systems. Its syntax and functionality are not dependent on the specific database system used. The same Rax code runs on MySQL[2] just as well as on SQL Server[3], which makes porting the code from one database platform to another quick and easy. In other words, Rax users are not locked into one specific database. Rax interpreter also runs atop big distributed databases like Amazon Redshift[4] or Snowflake[5], allowing Rax code to process petabytes of data.

[1] That said, Rax also allows importing data from files in various formats, such as CSV or XML

[2] MySQL is a registered trademark of MySQL AB in the United States, the European Union and other countries.

[3] SQL Server is a registered trademark of Microsoft Corporation in the U.S.A and/or other countries.

[4] Amazon Redshift is a registered trademark of Amazon Web Services, Inc.

[5] Snowflake is a registered trademark of Snowflake Computing Inc.