Hi, iv been stuck on question 2.5 for some time was looking for some help on it ..
**2.5. Given the function .viz.createDashboard
- profile it and refactor to improve performance
so that it completes execution in half the original time**
iv managed to chop the time to run down from 720 to about 500 by changing the select statement to functional form:
_ select from sensor where 0=lapId mod 2,sensorId in symbols,date in 2020.01.01 2020.01.02 _
?[sensor;((in;date;2020.01.01+0 1);(in;
sensorId;symbols);(=;0;(mod;
lapId;2))) ;0b;()]
im now looking into applying attributes to the table on disk.
iv tried using the dbmaint.q function:
setattr[dbdir;`sensor;`date;`g]
but it doesnt seem to be changing the attributes of the columns when i run _ meta sensor: _
c | t f a |
---|---|
date | d |
sensorId | s |
time | t |
lapId | j |
units | s |
sensorValue | f |
session | s |
Any help would be greatly appreciated.
Thanks,
Matthew