In Matlab I can do, for example, with "daynum" fractional day numbers:

idaynum = floor(daynum);
[umjd, im, iu] = unique(idaynum);  % <= how do I get the "iu" in Julia?

% I need an observation "pms" listed per day in a file.
% For performance reasons the parameter is retrieved from the file only 
once for each of the different integer days
upms = pi*umjd;   % <= for illustration only, instead of really retrieving 
the observed parameter
pms = upms(iu);
% Now "pms" matches "daynum", ie. when daynum=[1.0, 1.5, 1.8, 2.0, 2.2, 3.1
], then pms approx. [3.14, 3.14, 3.14, 6.28, 6.28, 9.42]

Probably this can be done elegantly also in Julia, but, coming from Matlab, 
for me not easy to see how?

Reply via email to