This page holds notes on how to port R code into ExaStat, for the purposes of compiling and speeding up run times.
Since ExaStat is C++ based, we must declare our variables. I recommend “Hungarian notation” in order to keep things easily readable - that is, make the first letter of your variable refer to the type.
These are traditional C++ variable types:
int iCount; // Comments are made like this... float fScore; /* or like this */ long iLongCount;
In R, objects were vectors by default. Here you must declare them using special types:
IntVar iRobot; FloatVar fDamage;
These types are also Classes in their own right, with built-in functions to accomplish particular tasks:
iStandings.Sum() iRobot.Mean()
CSV files are easy to read.
DataSet ds = ReadTextFile (”thing.csv”)
is as in R
tab ← read.csv(”thing.csv”)
though I don’t yet know about headers.
strcat_s(outputstr,addonstr)