Can you provide more details such as what you are trying to achieve and what the value of x is?
A projection is created whenever there is an elided argument in the argument list, no matter what the argument list is being applied to. In fact this allows you to create projections that have no useful purpose such as f:{x}[;;2] which will always either return another projection or throw a 'rank error.
I am trying to understand the .u.rep function in r.q:
.u.rep: (.[;();:;].)each x
Shouldn’t it apply the function to every item in x since we do “each”; it still needs the right-most dot to apply the function to each pair of x
Here, x: x:((trade;([]time:
time$();sym:$();price:
float$();size:int$()));(
quote;(time:time$();sym:
$();bid:float$();bsize:
int$();ask:float$();asize:
int$())));
Why does it create a projection? (without the right-most dot, it’s a projection):
.u.rep: (.[;();:;])each x