Home › Forums › KX Academy › error: "test.testTab" (FP.Functions.test/classifyTrades.quke:3) › Re: error: "test.testTab" (FP.Functions.test/classifyTrades.quke:3)
-
Hi Megan,
{[tab] //Pseudocode: //Performing an update will keep the original table //When classifying, need to first check the side //If side is Buy, then a good trade was bought for less than what the market was asking for //If side is Sell, then a good trade sold for more than what the market was bidding for //The vector conditional might prove useful s: exec side from select side from tab; b: exec bid from select bid from tab; a: exec ask from select ask from tab; p: exec price from select price from tab; exQuality: ?[s=`B;?[p<a;1b;0b];?[p>b;1b;0b]]; new: update exQuality from tab }