ParaMonte Fortran 2.0.0
Parallel Monte Carlo and Machine Learning Library
See the latest version documentation.
pm_arrayRefine::getRefined Interface Reference

Generate a refined version of the input array by the specified weight and skip.
More...

Detailed Description

Generate a refined version of the input array by the specified weight and skip.

Parameters
[in]array: The input contiguous array of shape (:) or (:,:) of either
  1. type character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU) or
  2. type integer of kind any supported by the processor (e.g., IK, IK8, IK16, IK32, or IK64) or
  3. type logical of kind any supported by the processor (e.g., LK) or
  4. type complex of kind any supported by the processor (e.g., CK, CK32, CK64, or CK128) or
  5. type real of kind any supported by the processor (e.g., RK, RK32, RK64, or RK128)
or,
  1. scalar character of kind any supported by the processor (e.g., SK, SKA, SKD , or SKU),
containing the array that has to be refined.
[in]dim: The input scalar of type integer of default kind IK representing the axis of array(:,:) along which array must be refined.
(optional, it must be present if and only if array is of shape (:,:).)
[in]weight: The input vector of
  1. type integer of default kind IK,
of size size(array, dim) containing the weights of individual elements of the input array.
[in]skip: The input scalar of type integer of default kind IK representing the number of elements to skip in the input sequence.
Returns
arrayRefined : The output allocatable array of the same type, kind, and shape as the input array, containing the refined unweighted version of the input array.
The returned array is unweighted to preserve the purity of the procedure.
See setRefined for an alternative interface.


Possible calling interfaces

arrayRefined = getRefined(array, weight, skip) ! scalar character objects.
arrayRefined(:) = getRefined(array(:), weight, skip) ! all intrinsic array objects.
arrayRefined(:,:) = getRefined(array(:,:), dim, weight, skip) ! all intrinsic array objects.
!
Generate a refined version of the input array by the specified weight and skip.
This module contains procedures and generic interfaces for refining (thinning) (weighted) arrays of a...
Warning
The condition 0 < skip must hold.
The condition dim == 1 .or. dim == 2 must hold.
The condition size(weight) == size(array) must hold when array is rank 1.
The condition size(weight) == size(array, dim) must hold when array is rank 2.
These conditions are verified only if the library is built with the preprocessor macro CHECK_ENABLED=1.
The pure procedure(s) documented herein become impure when the ParaMonte library is compiled with preprocessor macro CHECK_ENABLED=1.
By default, these procedures are pure in release build and impure in debug and testing builds.
Note
See pm_arrayCopy for refining unweighted strings and arrays.
See also
setRefined
getCompact
getVerbose
pm_arrayCopy


Example usage

1program example
2
6 use pm_distUnif, only: getUnifRand
7 use pm_distBern, only: isHead
8 use pm_kind, only: SK, IK, LK
9 use pm_io, only: display_type
10
11 implicit none
12
13 type(display_type) :: disp
14 integer(IK) :: nsam, itry, ntry = 10
15 disp = display_type(file = "main.out.F90")
16
17 call disp%skip()
18 call disp%show("!%%%%%%%%%%%%%%%%%")
19 call disp%show("! Refine 1D array.")
20 call disp%show("!%%%%%%%%%%%%%%%%%")
21 call disp%skip()
22
23 block
24
25 block
26 use pm_kind, only: TKG => SK ! all kinds are supported.
27 character(:,TKG), allocatable :: array
28 integer(IK), allocatable :: weight(:)
29 integer(IK) :: skip
30 do itry = 1, ntry
31 call disp%show("nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
32 nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
33 call disp%show("nsam")
34 call disp%show( nsam )
35 call disp%show("skip")
36 call disp%show( skip )
37 call disp%show("weight = getUnifRand(-1, 9, nsam)")
38 weight = getUnifRand(-1, 9, nsam)
39 call disp%show("weight")
40 call disp%show( weight )
41 call disp%show("array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))")
42 array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
43 call disp%show("array")
44 call disp%show( array , deliml = TKG_"""" )
45 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0))")
46 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0)) , deliml = TKG_"""" )
47 call disp%show("array = getRefined(array, weight, skip)")
48 array = getRefined(array, weight, skip)
49 call disp%show("array")
50 call disp%show( array , deliml = TKG_"""" )
51 call disp%skip()
52 end do
53 end block
54
55 block
56 use pm_kind, only: TKG => SK ! all kinds are supported.
57 character(2,TKG), allocatable :: array(:)
58 integer(IK), allocatable :: weight(:)
59 integer(IK) :: skip
60 do itry = 1, ntry
61 call disp%show("nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
62 nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
63 call disp%show("nsam")
64 call disp%show( nsam )
65 call disp%show("skip")
66 call disp%show( skip )
67 call disp%show("weight = getUnifRand(-1, 9, nsam)")
68 weight = getUnifRand(-1, 9, nsam)
69 call disp%show("weight")
70 call disp%show( weight )
71 call disp%show("array = getUnifRand('AA', 'ZZ', nsam)")
72 array = getUnifRand('AA', 'ZZ', nsam)
73 call disp%show("array")
74 call disp%show( array , deliml = TKG_"""" )
75 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0))")
76 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0)) , deliml = TKG_"""" )
77 call disp%show("array = getRefined(array, weight, skip)")
78 array = getRefined(array, weight, skip)
79 call disp%show("array")
80 call disp%show( array , deliml = TKG_"""" )
81 call disp%skip()
82 end do
83 end block
84
85 block
86 use pm_kind, only: TKG => IK ! all kinds are supported.
87 integer(TKG), allocatable :: array(:)
88 integer(IK), allocatable :: weight(:)
89 integer(IK) :: skip
90 do itry = 1, ntry
91 call disp%show("nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
92 nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
93 call disp%show("nsam")
94 call disp%show( nsam )
95 call disp%show("skip")
96 call disp%show( skip )
97 call disp%show("weight = getUnifRand(-1, 9, nsam)")
98 weight = getUnifRand(-1, 9, nsam)
99 call disp%show("weight")
100 call disp%show( weight )
101 call disp%show("array = getUnifRand(0, 9, nsam)")
102 array = getUnifRand(0, 9, nsam)
103 call disp%show("array")
104 call disp%show( array )
105 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0))")
106 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0)) )
107 call disp%show("array = getRefined(array, weight, skip)")
108 array = getRefined(array, weight, skip)
109 call disp%show("array")
110 call disp%show( array )
111 call disp%skip()
112 end do
113 end block
114
115 block
116 use pm_kind, only: TKG => LK ! all kinds are supported.
117 logical(TKG), allocatable :: array(:)
118 integer(IK), allocatable :: weight(:)
119 integer(IK) :: skip
120 do itry = 1, ntry
121 call disp%show("nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
122 nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
123 call disp%show("nsam")
124 call disp%show( nsam )
125 call disp%show("skip")
126 call disp%show( skip )
127 call disp%show("weight = getUnifRand(-1, 9, nsam)")
128 weight = getUnifRand(-1, 9, nsam)
129 call disp%show("weight")
130 call disp%show( weight )
131 call disp%show("array = getUnifRand(.false., .true., nsam)")
132 array = getUnifRand(.false., .true., nsam)
133 call disp%show("array")
134 call disp%show( array )
135 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0))")
136 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0)) )
137 call disp%show("array = getRefined(array, weight, skip)")
138 array = getRefined(array, weight, skip)
139 call disp%show("array")
140 call disp%show( array )
141 call disp%skip()
142 end do
143 end block
144
145 block
146 use pm_kind, only: TKG => CKS ! all kinds are supported.
147 complex(TKG), allocatable :: array(:)
148 integer(IK), allocatable :: weight(:)
149 integer(IK) :: skip
150 do itry = 1, ntry
151 call disp%show("nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
152 nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
153 call disp%show("nsam")
154 call disp%show( nsam )
155 call disp%show("skip")
156 call disp%show( skip )
157 call disp%show("weight = getUnifRand(-1, 9, nsam)")
158 weight = getUnifRand(-1, 9, nsam)
159 call disp%show("weight")
160 call disp%show( weight )
161 call disp%show("array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)")
162 array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
163 call disp%show("array")
164 call disp%show( array )
165 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0))")
166 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0)) )
167 call disp%show("array = getRefined(array, weight, skip)")
168 array = getRefined(array, weight, skip)
169 call disp%show("array")
170 call disp%show( array )
171 call disp%skip()
172 end do
173 end block
174
175 block
176 use pm_kind, only: TKG => RKS ! all kinds are supported.
177 real(TKG), allocatable :: array(:)
178 integer(IK), allocatable :: weight(:)
179 integer(IK) :: skip
180 do itry = 1, ntry
181 call disp%show("nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
182 nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
183 call disp%show("nsam")
184 call disp%show( nsam )
185 call disp%show("skip")
186 call disp%show( skip )
187 call disp%show("weight = getUnifRand(-1, 9, nsam)")
188 weight = getUnifRand(-1, 9, nsam)
189 call disp%show("weight")
190 call disp%show( weight )
191 call disp%show("array = getUnifRand(0, 9, nsam)")
192 array = getUnifRand(0, 9, nsam)
193 call disp%show("array")
194 call disp%show( array )
195 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0))")
196 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0)) )
197 call disp%show("array = getRefined(array, weight, skip)")
198 array = getRefined(array, weight, skip)
199 call disp%show("array")
200 call disp%show( array )
201 call disp%skip()
202 end do
203 end block
204
205 end block
206
207 call disp%skip()
208 call disp%show("!%%%%%%%%%%%%%%%%%")
209 call disp%show("! Refine 2D array.")
210 call disp%show("!%%%%%%%%%%%%%%%%%")
211 call disp%skip()
212
213 block
214
215 integer(IK) :: dim, ndim
216
217 block
218 use pm_kind, only: TKG => SK ! all kinds are supported.
219 character(2,TKG), allocatable :: array(:,:), arref(:,:)
220 integer(IK), allocatable :: weight(:)
221 integer(IK) :: skip
222 do itry = 1, ntry
223 call disp%show("dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
224 dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
225 call disp%show("[dim, ndim, nsam]")
226 call disp%show( [dim, ndim, nsam] )
227 call disp%show("skip")
228 call disp%show( skip )
229 call disp%show("weight = getUnifRand(-1, 9, nsam)")
230 weight = getUnifRand(-1, 9, nsam)
231 call disp%show("weight")
232 call disp%show( weight )
233 call disp%show("array = getUnifRand('AA', 'ZZ', ndim, nsam)")
234 array = getUnifRand('AA', 'ZZ', ndim, nsam)
235 call disp%show("array")
236 call disp%show( array , deliml = TKG_"""" )
237 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0), dim)")
238 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0), dim) , deliml = TKG_"""" )
239 call disp%show("arref = getRefined(array, dim, weight, skip)")
240 arref = getRefined(array, dim, weight, skip)
241 call disp%show("arref")
242 call disp%show( arref , deliml = TKG_"""" )
243 call disp%show("arref = getRefined(transpose(array), 3_IK - dim, weight, skip)")
244 arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
245 call disp%show("arref")
246 call disp%show( arref , deliml = TKG_"""" )
247 call disp%skip()
248 end do
249 end block
250
251 block
252 use pm_kind, only: TKG => IK ! all kinds are supported.
253 integer(TKG), allocatable :: array(:,:), arref(:,:)
254 integer(IK), allocatable :: weight(:)
255 integer(IK) :: skip
256 do itry = 1, ntry
257 call disp%show("dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
258 dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
259 call disp%show("[dim, ndim, nsam]")
260 call disp%show( [dim, ndim, nsam] )
261 call disp%show("skip")
262 call disp%show( skip )
263 call disp%show("weight = getUnifRand(-1, 9, nsam)")
264 weight = getUnifRand(-1, 9, nsam)
265 call disp%show("weight")
266 call disp%show( weight )
267 call disp%show("array = getUnifRand(0, 9, ndim, nsam)")
268 array = getUnifRand(0, 9, ndim, nsam)
269 call disp%show("array")
270 call disp%show( array )
271 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0), dim)")
272 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0), dim) )
273 call disp%show("arref = getRefined(array, dim, weight, skip)")
274 arref = getRefined(array, dim, weight, skip)
275 call disp%show("arref")
276 call disp%show( arref )
277 call disp%show("arref = getRefined(transpose(array), 3_IK - dim, weight, skip)")
278 arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
279 call disp%show("arref")
280 call disp%show( arref )
281 call disp%skip()
282 end do
283 end block
284
285 block
286 use pm_kind, only: TKG => LK ! all kinds are supported.
287 logical(TKG), allocatable :: array(:,:), arref(:,:)
288 integer(IK), allocatable :: weight(:)
289 integer(IK) :: skip
290 do itry = 1, ntry
291 call disp%show("dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
292 dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
293 call disp%show("[dim, ndim, nsam]")
294 call disp%show( [dim, ndim, nsam] )
295 call disp%show("skip")
296 call disp%show( skip )
297 call disp%show("weight = getUnifRand(-1, 9, nsam)")
298 weight = getUnifRand(-1, 9, nsam)
299 call disp%show("weight")
300 call disp%show( weight )
301 call disp%show("array = getUnifRand(.false., .true., ndim, nsam)")
302 array = getUnifRand(.false., .true., ndim, nsam)
303 call disp%show("array")
304 call disp%show( array )
305 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0), dim)")
306 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0), dim) )
307 call disp%show("arref = getRefined(array, dim, weight, skip)")
308 arref = getRefined(array, dim, weight, skip)
309 call disp%show("arref")
310 call disp%show( arref )
311 call disp%show("arref = getRefined(transpose(array), 3_IK - dim, weight, skip)")
312 arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
313 call disp%show("arref")
314 call disp%show( arref )
315 call disp%skip()
316 end do
317 end block
318
319 block
320 use pm_kind, only: TKG => CKS ! all kinds are supported.
321 complex(TKG), allocatable :: array(:,:), arref(:,:)
322 integer(IK), allocatable :: weight(:)
323 integer(IK) :: skip
324 do itry = 1, ntry
325 call disp%show("dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
326 dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
327 call disp%show("[dim, ndim, nsam]")
328 call disp%show( [dim, ndim, nsam] )
329 call disp%show("skip")
330 call disp%show( skip )
331 call disp%show("weight = getUnifRand(-1, 9, nsam)")
332 weight = getUnifRand(-1, 9, nsam)
333 call disp%show("weight")
334 call disp%show( weight )
335 call disp%show("array = cmplx(getUnifRand(0, 9, ndim, nsam), getUnifRand(0, 9, ndim, nsam), TKG)")
336 array = cmplx(getUnifRand(0, 9, ndim, nsam), getUnifRand(0, 9, ndim, nsam), TKG)
337 call disp%show("array")
338 call disp%show( array )
339 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0), dim)")
340 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0), dim) )
341 call disp%show("arref = getRefined(array, dim, weight, skip)")
342 arref = getRefined(array, dim, weight, skip)
343 call disp%show("arref")
344 call disp%show( arref )
345 call disp%show("arref = getRefined(transpose(array), 3_IK - dim, weight, skip)")
346 arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
347 call disp%show("arref")
348 call disp%show( arref )
349 call disp%skip()
350 end do
351 end block
352
353 block
354 use pm_kind, only: TKG => RKS ! all kinds are supported.
355 real(TKG), allocatable :: array(:,:), arref(:,:)
356 integer(IK), allocatable :: weight(:)
357 integer(IK) :: skip
358 do itry = 1, ntry
359 call disp%show("dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)")
360 dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
361 call disp%show("[dim, ndim, nsam]")
362 call disp%show( [dim, ndim, nsam] )
363 call disp%show("skip")
364 call disp%show( skip )
365 call disp%show("weight = getUnifRand(-1, 9, nsam)")
366 weight = getUnifRand(-1, 9, nsam)
367 call disp%show("weight")
368 call disp%show( weight )
369 call disp%show("array = getUnifRand(0, 9, ndim, nsam)")
370 array = getUnifRand(0, 9, ndim, nsam)
371 call disp%show("array")
372 call disp%show( array )
373 call disp%show("getVerbose(array, weight, sum(weight, mask = weight > 0), dim)")
374 call disp%show( getVerbose(array, weight, sum(weight, mask = weight > 0), dim) )
375 call disp%show("arref = getRefined(array, dim, weight, skip)")
376 arref = getRefined(array, dim, weight, skip)
377 call disp%show("arref")
378 call disp%show( arref )
379 call disp%show("arref = getRefined(transpose(array), 3_IK - dim, weight, skip)")
380 arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
381 call disp%show("arref")
382 call disp%show( arref )
383 call disp%skip()
384 end do
385 end block
386
387 end block
388
389end program example
Select a single (or multiple) element(s) from the input array of intrinsic type of arbitrary kind ran...
Generate an equally-weighted (verbose or flattened) array of the input weighted array of rank 1 or 2.
Generate and return a scalar (or a vector of length size or an array of the same shape as the input p...
Generate and return a scalar or a contiguous array of rank 1 of length s1 of randomly uniformly distr...
This is a generic method of the derived type display_type with pass attribute.
Definition: pm_io.F90:11726
This is a generic method of the derived type display_type with pass attribute.
Definition: pm_io.F90:11508
This module contains procedures and generic interfaces for selecting uniformly-distributed or arbitra...
This module contains procedures and generic interfaces for flattening (duplicating the elements of) a...
This module contains classes and procedures for generating Bernoulli-distributed random numbers.
Definition: pm_distBern.F90:39
This module contains classes and procedures for computing various statistical quantities related to t...
This module contains classes and procedures for input/output (IO) or generic display operations on st...
Definition: pm_io.F90:252
type(display_type) disp
This is a scalar module variable an object of type display_type for general display.
Definition: pm_io.F90:11393
This module defines the relevant Fortran kind type-parameters frequently used in the ParaMonte librar...
Definition: pm_kind.F90:268
integer, parameter LK
The default logical kind in the ParaMonte library: kind(.true.) in Fortran, kind(....
Definition: pm_kind.F90:541
integer, parameter CKS
The single-precision complex kind in Fortran mode. On most platforms, this is a 32-bit real kind.
Definition: pm_kind.F90:570
integer, parameter IK
The default integer kind in the ParaMonte library: int32 in Fortran, c_int32_t in C-Fortran Interoper...
Definition: pm_kind.F90:540
integer, parameter SK
The default character kind in the ParaMonte library: kind("a") in Fortran, c_char in C-Fortran Intero...
Definition: pm_kind.F90:539
integer, parameter RKS
The single-precision real kind in Fortran mode. On most platforms, this is an 32-bit real kind.
Definition: pm_kind.F90:567
Generate and return an object of type display_type.
Definition: pm_io.F90:10282

Example Unix compile command via Intel ifort compiler
1#!/usr/bin/env sh
2rm main.exe
3ifort -fpp -standard-semantics -O3 -Wl,-rpath,../../../lib -I../../../inc main.F90 ../../../lib/libparamonte* -o main.exe
4./main.exe

Example Windows Batch compile command via Intel ifort compiler
1del main.exe
2set PATH=..\..\..\lib;%PATH%
3ifort /fpp /standard-semantics /O3 /I:..\..\..\include main.F90 ..\..\..\lib\libparamonte*.lib /exe:main.exe
4main.exe

Example Unix / MinGW compile command via GNU gfortran compiler
1#!/usr/bin/env sh
2rm main.exe
3gfortran -cpp -ffree-line-length-none -O3 -Wl,-rpath,../../../lib -I../../../inc main.F90 ../../../lib/libparamonte* -o main.exe
4./main.exe

Example output
1
2!%%%%%%%%%%%%%%%%%
3! Refine 1D array.
4!%%%%%%%%%%%%%%%%%
5
6nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
7nsam
8+7
10+3
11weight = getUnifRand(-1, 9, nsam)
12weight
13+1, +5, +0, +1, +2, +1, +0
14array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
15array
16"NZOLSJV"
17getVerbose(array, weight, sum(weight, mask = weight > 0))
18"NZZZZZLSSJ"
19array = getRefined(array, weight, skip)
20array
21"ZZS"
22
23nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
24nsam
25+3
26skip
27+4
28weight = getUnifRand(-1, 9, nsam)
29weight
30+6, +2, -1
31array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
32array
33"AQC"
34getVerbose(array, weight, sum(weight, mask = weight > 0))
35"AAAAAAQQ"
36array = getRefined(array, weight, skip)
37array
38"AQ"
39
40nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
41nsam
42+2
43skip
44+3
45weight = getUnifRand(-1, 9, nsam)
46weight
47+3, +7
48array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
49array
50"UB"
51getVerbose(array, weight, sum(weight, mask = weight > 0))
52"UUUBBBBBBB"
53array = getRefined(array, weight, skip)
54array
55"UBB"
56
57nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
58nsam
59+4
60skip
61+3
62weight = getUnifRand(-1, 9, nsam)
63weight
64+2, -1, +0, +1
65array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
66array
67"VCCJ"
68getVerbose(array, weight, sum(weight, mask = weight > 0))
69"VVJ"
70array = getRefined(array, weight, skip)
71array
72"J"
73
74nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
75nsam
76+8
77skip
78+3
79weight = getUnifRand(-1, 9, nsam)
80weight
81+5, +2, -1, +3, +4, +9, +9, +7
82array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
83array
84"XZOIADYH"
85getVerbose(array, weight, sum(weight, mask = weight > 0))
86"XXXXXZZIIIAAAADDDDDDDDDYYYYYYYYYHHHHHHH"
87array = getRefined(array, weight, skip)
88array
89"XZIADDDYYYHHH"
90
91nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
92nsam
93+5
94skip
95+2
96weight = getUnifRand(-1, 9, nsam)
97weight
98+6, +0, +7, +4, +7
99array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
100array
101"MFHUX"
102getVerbose(array, weight, sum(weight, mask = weight > 0))
103"MMMMMMHHHHHHHUUUUXXXXXXX"
104array = getRefined(array, weight, skip)
105array
106"MMMHHHUUXXXX"
107
108nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
109nsam
110+9
111skip
112+1
113weight = getUnifRand(-1, 9, nsam)
114weight
115+5, +6, +6, +8, +2, +4, +9, +7, +5
116array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
117array
118"QYRCOTGKX"
119getVerbose(array, weight, sum(weight, mask = weight > 0))
120"QQQQQYYYYYYRRRRRRCCCCCCCCOOTTTTGGGGGGGGGKKKKKKKXXXXX"
121array = getRefined(array, weight, skip)
122array
123"QQQQQYYYYYYRRRRRRCCCCCCCCOOTTTTGGGGGGGGGKKKKKKKXXXXX"
124
125nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
126nsam
127+9
128skip
129+1
130weight = getUnifRand(-1, 9, nsam)
131weight
132-1, +5, +3, +6, +5, +6, +6, +2, -1
133array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
134array
135"UUUIMDKNR"
136getVerbose(array, weight, sum(weight, mask = weight > 0))
137"UUUUUUUUIIIIIIMMMMMDDDDDDKKKKKKNN"
138array = getRefined(array, weight, skip)
139array
140"UUUUUUUUIIIIIIMMMMMDDDDDDKKKKKKNN"
141
142nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
143nsam
144+9
145skip
146+2
147weight = getUnifRand(-1, 9, nsam)
148weight
149+6, +2, +0, +3, +4, +2, +0, +5, +3
150array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
151array
152"RCVLJCWMT"
153getVerbose(array, weight, sum(weight, mask = weight > 0))
154"RRRRRRCCLLLJJJJCCMMMMMTTT"
155array = getRefined(array, weight, skip)
156array
157"RRRCLJJCMMMT"
158
159nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
160nsam
161+9
162skip
163+4
164weight = getUnifRand(-1, 9, nsam)
165weight
166+4, +8, +8, -1, +7, +4, -1, +2, +9
167array = getUnifRand(repeat('A', nsam), repeat('Z', nsam))
168array
169"SZUHRYLQT"
170getVerbose(array, weight, sum(weight, mask = weight > 0))
171"SSSSZZZZZZZZUUUUUUUURRRRRRRYYYYQQTTTTTTTTT"
172array = getRefined(array, weight, skip)
173array
174"SZZUURYQTT"
175
176nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
177nsam
178+2
179skip
180+3
181weight = getUnifRand(-1, 9, nsam)
182weight
183+0, +6
184array = getUnifRand('AA', 'ZZ', nsam)
185array
186"AL", "IP"
187getVerbose(array, weight, sum(weight, mask = weight > 0))
188"IP", "IP", "IP", "IP", "IP", "IP"
189array = getRefined(array, weight, skip)
190array
191"IP", "IP"
192
193nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
194nsam
195+6
196skip
197+4
198weight = getUnifRand(-1, 9, nsam)
199weight
200+2, +7, +3, +7, -1, +9
201array = getUnifRand('AA', 'ZZ', nsam)
202array
203"IQ", "NM", "RB", "LI", "BO", "RJ"
204getVerbose(array, weight, sum(weight, mask = weight > 0))
205"IQ", "IQ", "NM", "NM", "NM", "NM", "NM", "NM", "NM", "RB", "RB", "RB", "LI", "LI", "LI", "LI", "LI", "LI", "LI", "RJ", "RJ", "RJ", "RJ", "RJ", "RJ", "RJ", "RJ", "RJ"
206array = getRefined(array, weight, skip)
207array
208"NM", "NM", "RB", "LI", "RJ", "RJ", "RJ"
209
210nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
211nsam
212+0
213skip
214+2
215weight = getUnifRand(-1, 9, nsam)
216weight
217
218array = getUnifRand('AA', 'ZZ', nsam)
219array
220
221getVerbose(array, weight, sum(weight, mask = weight > 0))
222
223array = getRefined(array, weight, skip)
224array
225
226
227nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
228nsam
229+7
230skip
231+1
232weight = getUnifRand(-1, 9, nsam)
233weight
234+7, +9, -1, +5, +6, +1, +6
235array = getUnifRand('AA', 'ZZ', nsam)
236array
237"CC", "GN", "MV", "FK", "QY", "MR", "WG"
238getVerbose(array, weight, sum(weight, mask = weight > 0))
239"CC", "CC", "CC", "CC", "CC", "CC", "CC", "GN", "GN", "GN", "GN", "GN", "GN", "GN", "GN", "GN", "FK", "FK", "FK", "FK", "FK", "QY", "QY", "QY", "QY", "QY", "QY", "MR", "WG", "WG", "WG", "WG", "WG", "WG"
240array = getRefined(array, weight, skip)
241array
242"CC", "CC", "CC", "CC", "CC", "CC", "CC", "GN", "GN", "GN", "GN", "GN", "GN", "GN", "GN", "GN", "FK", "FK", "FK", "FK", "FK", "QY", "QY", "QY", "QY", "QY", "QY", "MR", "WG", "WG", "WG", "WG", "WG", "WG"
243
244nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
245nsam
246+3
247skip
248+3
249weight = getUnifRand(-1, 9, nsam)
250weight
251+5, -1, +6
252array = getUnifRand('AA', 'ZZ', nsam)
253array
254"ZW", "RK", "UA"
255getVerbose(array, weight, sum(weight, mask = weight > 0))
256"ZW", "ZW", "ZW", "ZW", "ZW", "UA", "UA", "UA", "UA", "UA", "UA"
257array = getRefined(array, weight, skip)
258array
259"ZW", "UA", "UA"
260
261nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
262nsam
263+2
264skip
265+1
266weight = getUnifRand(-1, 9, nsam)
267weight
268+5, +0
269array = getUnifRand('AA', 'ZZ', nsam)
270array
271"GP", "DR"
272getVerbose(array, weight, sum(weight, mask = weight > 0))
273"GP", "GP", "GP", "GP", "GP"
274array = getRefined(array, weight, skip)
275array
276"GP", "GP", "GP", "GP", "GP"
277
278nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
279nsam
280+7
281skip
282+3
283weight = getUnifRand(-1, 9, nsam)
284weight
285+1, +4, +4, +6, +3, +6, +7
286array = getUnifRand('AA', 'ZZ', nsam)
287array
288"GH", "IL", "IY", "HN", "WQ", "SQ", "VT"
289getVerbose(array, weight, sum(weight, mask = weight > 0))
290"GH", "IL", "IL", "IL", "IL", "IY", "IY", "IY", "IY", "HN", "HN", "HN", "HN", "HN", "HN", "WQ", "WQ", "WQ", "SQ", "SQ", "SQ", "SQ", "SQ", "SQ", "VT", "VT", "VT", "VT", "VT", "VT", "VT"
291array = getRefined(array, weight, skip)
292array
293"IL", "IY", "IY", "HN", "HN", "WQ", "SQ", "SQ", "VT", "VT"
294
295nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
296nsam
297+0
298skip
299+3
300weight = getUnifRand(-1, 9, nsam)
301weight
302
303array = getUnifRand('AA', 'ZZ', nsam)
304array
305
306getVerbose(array, weight, sum(weight, mask = weight > 0))
307
308array = getRefined(array, weight, skip)
309array
310
311
312nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
313nsam
314+1
315skip
316+2
317weight = getUnifRand(-1, 9, nsam)
318weight
319+2
320array = getUnifRand('AA', 'ZZ', nsam)
321array
322"TQ"
323getVerbose(array, weight, sum(weight, mask = weight > 0))
324"TQ", "TQ"
325array = getRefined(array, weight, skip)
326array
327"TQ"
328
329nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
330nsam
331+0
332skip
333+2
334weight = getUnifRand(-1, 9, nsam)
335weight
336
337array = getUnifRand('AA', 'ZZ', nsam)
338array
339
340getVerbose(array, weight, sum(weight, mask = weight > 0))
341
342array = getRefined(array, weight, skip)
343array
344
345
346nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
347nsam
348+7
349skip
350+1
351weight = getUnifRand(-1, 9, nsam)
352weight
353+8, +5, +5, +8, +5, +8, +4
354array = getUnifRand(0, 9, nsam)
355array
356+1, +7, +7, +4, +4, +2, +1
357getVerbose(array, weight, sum(weight, mask = weight > 0))
358+1, +1, +1, +1, +1, +1, +1, +1, +7, +7, +7, +7, +7, +7, +7, +7, +7, +7, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +2, +2, +2, +2, +2, +2, +2, +2, +1, +1, +1, +1
359array = getRefined(array, weight, skip)
360array
361+1, +1, +1, +1, +1, +1, +1, +1, +7, +7, +7, +7, +7, +7, +7, +7, +7, +7, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +4, +2, +2, +2, +2, +2, +2, +2, +2, +1, +1, +1, +1
362
363nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
364nsam
365+5
366skip
367+2
368weight = getUnifRand(-1, 9, nsam)
369weight
370+9, +4, +2, +5, +5
371array = getUnifRand(0, 9, nsam)
372array
373+9, +4, +4, +2, +2
374getVerbose(array, weight, sum(weight, mask = weight > 0))
375+9, +9, +9, +9, +9, +9, +9, +9, +9, +4, +4, +4, +4, +4, +4, +2, +2, +2, +2, +2, +2, +2, +2, +2, +2
376array = getRefined(array, weight, skip)
377array
378+9, +9, +9, +9, +4, +4, +4, +2, +2, +2, +2, +2
379
380nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
381nsam
382+4
383skip
384+4
385weight = getUnifRand(-1, 9, nsam)
386weight
387+3, +8, +8, +1
388array = getUnifRand(0, 9, nsam)
389array
390+7, +0, +4, +6
391getVerbose(array, weight, sum(weight, mask = weight > 0))
392+7, +7, +7, +0, +0, +0, +0, +0, +0, +0, +0, +4, +4, +4, +4, +4, +4, +4, +4, +6
393array = getRefined(array, weight, skip)
394array
395+0, +0, +4, +4, +6
396
397nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
398nsam
399+0
400skip
401+4
402weight = getUnifRand(-1, 9, nsam)
403weight
404
405array = getUnifRand(0, 9, nsam)
406array
407
408getVerbose(array, weight, sum(weight, mask = weight > 0))
409
410array = getRefined(array, weight, skip)
411array
412
413
414nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
415nsam
416+2
417skip
418+1
419weight = getUnifRand(-1, 9, nsam)
420weight
421+9, +5
422array = getUnifRand(0, 9, nsam)
423array
424+3, +2
425getVerbose(array, weight, sum(weight, mask = weight > 0))
426+3, +3, +3, +3, +3, +3, +3, +3, +3, +2, +2, +2, +2, +2
427array = getRefined(array, weight, skip)
428array
429+3, +3, +3, +3, +3, +3, +3, +3, +3, +2, +2, +2, +2, +2
430
431nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
432nsam
433+5
434skip
435+4
436weight = getUnifRand(-1, 9, nsam)
437weight
438+4, -1, +3, +8, +3
439array = getUnifRand(0, 9, nsam)
440array
441+5, +6, +4, +3, +1
442getVerbose(array, weight, sum(weight, mask = weight > 0))
443+5, +5, +5, +5, +4, +4, +4, +3, +3, +3, +3, +3, +3, +3, +3, +1, +1, +1
444array = getRefined(array, weight, skip)
445array
446+5, +3, +3, +1
447
448nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
449nsam
450+9
451skip
452+2
453weight = getUnifRand(-1, 9, nsam)
454weight
455+8, +7, +5, +7, +1, +6, +0, +6, +0
456array = getUnifRand(0, 9, nsam)
457array
458+2, +5, +7, +6, +6, +9, +6, +6, +1
459getVerbose(array, weight, sum(weight, mask = weight > 0))
460+2, +2, +2, +2, +2, +2, +2, +2, +5, +5, +5, +5, +5, +5, +5, +7, +7, +7, +7, +7, +6, +6, +6, +6, +6, +6, +6, +6, +9, +9, +9, +9, +9, +9, +6, +6, +6, +6, +6, +6
461array = getRefined(array, weight, skip)
462array
463+2, +2, +2, +2, +5, +5, +5, +7, +7, +7, +6, +6, +6, +6, +9, +9, +9, +6, +6, +6
464
465nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
466nsam
467+5
468skip
469+3
470weight = getUnifRand(-1, 9, nsam)
471weight
472+7, +6, +3, +6, +9
473array = getUnifRand(0, 9, nsam)
474array
475+2, +3, +9, +7, +5
476getVerbose(array, weight, sum(weight, mask = weight > 0))
477+2, +2, +2, +2, +2, +2, +2, +3, +3, +3, +3, +3, +3, +9, +9, +9, +7, +7, +7, +7, +7, +7, +5, +5, +5, +5, +5, +5, +5, +5, +5
478array = getRefined(array, weight, skip)
479array
480+2, +2, +3, +3, +9, +7, +7, +5, +5, +5
481
482nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
483nsam
484+5
485skip
486+2
487weight = getUnifRand(-1, 9, nsam)
488weight
489+6, +9, +1, +3, +7
490array = getUnifRand(0, 9, nsam)
491array
492+1, +1, +6, +3, +5
493getVerbose(array, weight, sum(weight, mask = weight > 0))
494+1, +1, +1, +1, +1, +1, +1, +1, +1, +1, +1, +1, +1, +1, +1, +6, +3, +3, +3, +5, +5, +5, +5, +5, +5, +5
495array = getRefined(array, weight, skip)
496array
497+1, +1, +1, +1, +1, +1, +1, +6, +3, +5, +5, +5, +5
498
499nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
500nsam
501+7
502skip
503+3
504weight = getUnifRand(-1, 9, nsam)
505weight
506+3, +7, +8, +7, +3, -1, +4
507array = getUnifRand(0, 9, nsam)
508array
509+8, +0, +7, +3, +0, +9, +7
510getVerbose(array, weight, sum(weight, mask = weight > 0))
511+8, +8, +8, +0, +0, +0, +0, +0, +0, +0, +7, +7, +7, +7, +7, +7, +7, +7, +3, +3, +3, +3, +3, +3, +3, +0, +0, +0, +7, +7, +7, +7
512array = getRefined(array, weight, skip)
513array
514+8, +0, +0, +7, +7, +7, +3, +3, +0, +7
515
516nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
517nsam
518+1
519skip
520+3
521weight = getUnifRand(-1, 9, nsam)
522weight
523+8
524array = getUnifRand(.false., .true., nsam)
525array
526F
527getVerbose(array, weight, sum(weight, mask = weight > 0))
528F, F, F, F, F, F, F, F
529array = getRefined(array, weight, skip)
530array
531F, F
532
533nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
534nsam
535+6
536skip
537+4
538weight = getUnifRand(-1, 9, nsam)
539weight
540+7, +4, +7, +7, +8, +3
541array = getUnifRand(.false., .true., nsam)
542array
543F, T, T, F, F, T
544getVerbose(array, weight, sum(weight, mask = weight > 0))
545F, F, F, F, F, F, F, T, T, T, T, T, T, T, T, T, T, T, F, F, F, F, F, F, F, F, F, F, F, F, F, F, F, T, T, T
546array = getRefined(array, weight, skip)
547array
548F, T, T, T, F, F, F, F, T
549
550nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
551nsam
552+7
553skip
554+3
555weight = getUnifRand(-1, 9, nsam)
556weight
557+2, +4, +6, +2, +8, -1, +7
558array = getUnifRand(.false., .true., nsam)
559array
560T, T, T, F, T, F, T
561getVerbose(array, weight, sum(weight, mask = weight > 0))
562T, T, T, T, T, T, T, T, T, T, T, T, F, F, T, T, T, T, T, T, T, T, T, T, T, T, T, T, T
563array = getRefined(array, weight, skip)
564array
565T, T, T, T, T, T, T, T, T
566
567nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
568nsam
569+1
570skip
571+3
572weight = getUnifRand(-1, 9, nsam)
573weight
574+1
575array = getUnifRand(.false., .true., nsam)
576array
577T
578getVerbose(array, weight, sum(weight, mask = weight > 0))
579T
580array = getRefined(array, weight, skip)
581array
582
583
584nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
585nsam
586+2
587skip
588+4
589weight = getUnifRand(-1, 9, nsam)
590weight
591+8, +1
592array = getUnifRand(.false., .true., nsam)
593array
594F, T
595getVerbose(array, weight, sum(weight, mask = weight > 0))
596F, F, F, F, F, F, F, F, T
597array = getRefined(array, weight, skip)
598array
599F, F
600
601nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
602nsam
603+8
604skip
605+2
606weight = getUnifRand(-1, 9, nsam)
607weight
608+3, +5, +7, +1, +4, +6, +1, +1
609array = getUnifRand(.false., .true., nsam)
610array
611T, T, F, T, T, F, T, T
612getVerbose(array, weight, sum(weight, mask = weight > 0))
613T, T, T, T, T, T, T, T, F, F, F, F, F, F, F, T, T, T, T, T, F, F, F, F, F, F, T, T
614array = getRefined(array, weight, skip)
615array
616T, T, T, T, F, F, F, T, T, T, F, F, F, T
617
618nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
619nsam
620+4
621skip
622+3
623weight = getUnifRand(-1, 9, nsam)
624weight
625+5, +8, -1, +3
626array = getUnifRand(.false., .true., nsam)
627array
628F, F, F, T
629getVerbose(array, weight, sum(weight, mask = weight > 0))
630F, F, F, F, F, F, F, F, F, F, F, F, F, T, T, T
631array = getRefined(array, weight, skip)
632array
633F, F, F, F, T
634
635nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
636nsam
637+0
638skip
639+3
640weight = getUnifRand(-1, 9, nsam)
641weight
642
643array = getUnifRand(.false., .true., nsam)
644array
645
646getVerbose(array, weight, sum(weight, mask = weight > 0))
647
648array = getRefined(array, weight, skip)
649array
650
651
652nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
653nsam
654+9
655skip
656+3
657weight = getUnifRand(-1, 9, nsam)
658weight
659+6, +2, +8, -1, +3, +1, +0, +8, +2
660array = getUnifRand(.false., .true., nsam)
661array
662F, T, T, T, F, F, F, T, T
663getVerbose(array, weight, sum(weight, mask = weight > 0))
664F, F, F, F, F, F, T, T, T, T, T, T, T, T, T, T, F, F, F, F, T, T, T, T, T, T, T, T, T, T
665array = getRefined(array, weight, skip)
666array
667F, F, T, T, T, F, T, T, T, T
668
669nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
670nsam
671+7
672skip
673+3
674weight = getUnifRand(-1, 9, nsam)
675weight
676-1, +2, +7, +3, -1, +0, +9
677array = getUnifRand(.false., .true., nsam)
678array
679T, T, F, F, T, T, F
680getVerbose(array, weight, sum(weight, mask = weight > 0))
681T, T, F, F, F, F, F, F, F, F, F, F, F, F, F, F, F, F, F, F, F
682array = getRefined(array, weight, skip)
683array
684F, F, F, F, F, F, F
685
686nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
687nsam
688+7
689skip
690+4
691weight = getUnifRand(-1, 9, nsam)
692weight
693+8, +0, +4, -1, +0, +9, +3
694array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
695array
696(+8.00000000, +5.00000000), (+2.00000000, +3.00000000), (+2.00000000, +4.00000000), (+5.00000000, +4.00000000), (+3.00000000, +7.00000000), (+2.00000000, +4.00000000), (+8.00000000, +0.00000000)
697getVerbose(array, weight, sum(weight, mask = weight > 0))
698(+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000)
699array = getRefined(array, weight, skip)
700array
701(+8.00000000, +5.00000000), (+8.00000000, +5.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+2.00000000, +4.00000000), (+8.00000000, +0.00000000)
702
703nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
704nsam
705+3
706skip
707+4
708weight = getUnifRand(-1, 9, nsam)
709weight
710+2, +0, +5
711array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
712array
713(+8.00000000, +7.00000000), (+8.00000000, +2.00000000), (+5.00000000, +9.00000000)
714getVerbose(array, weight, sum(weight, mask = weight > 0))
715(+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+5.00000000, +9.00000000), (+5.00000000, +9.00000000), (+5.00000000, +9.00000000), (+5.00000000, +9.00000000), (+5.00000000, +9.00000000)
716array = getRefined(array, weight, skip)
717array
718(+5.00000000, +9.00000000)
719
720nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
721nsam
722+3
723skip
724+2
725weight = getUnifRand(-1, 9, nsam)
726weight
727+8, +5, +8
728array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
729array
730(+1.00000000, +8.00000000), (+2.00000000, +7.00000000), (+4.00000000, +0.00000000)
731getVerbose(array, weight, sum(weight, mask = weight > 0))
732(+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+2.00000000, +7.00000000), (+2.00000000, +7.00000000), (+2.00000000, +7.00000000), (+2.00000000, +7.00000000), (+2.00000000, +7.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000)
733array = getRefined(array, weight, skip)
734array
735(+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+1.00000000, +8.00000000), (+2.00000000, +7.00000000), (+2.00000000, +7.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000)
736
737nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
738nsam
739+5
740skip
741+1
742weight = getUnifRand(-1, 9, nsam)
743weight
744+3, +1, +4, +6, +5
745array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
746array
747(+5.00000000, +1.00000000), (+4.00000000, +6.00000000), (+1.00000000, +4.00000000), (+2.00000000, +5.00000000), (+5.00000000, +5.00000000)
748getVerbose(array, weight, sum(weight, mask = weight > 0))
749(+5.00000000, +1.00000000), (+5.00000000, +1.00000000), (+5.00000000, +1.00000000), (+4.00000000, +6.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000)
750array = getRefined(array, weight, skip)
751array
752(+5.00000000, +1.00000000), (+5.00000000, +1.00000000), (+5.00000000, +1.00000000), (+4.00000000, +6.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+2.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000), (+5.00000000, +5.00000000)
753
754nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
755nsam
756+9
757skip
758+2
759weight = getUnifRand(-1, 9, nsam)
760weight
761+5, +5, +7, +3, +4, +2, +1, +1, +4
762array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
763array
764(+6.00000000, +9.00000000), (+8.00000000, +0.00000000), (+8.00000000, +7.00000000), (+1.00000000, +4.00000000), (+7.00000000, +4.00000000), (+2.00000000, +3.00000000), (+2.00000000, +6.00000000), (+2.00000000, +4.00000000), (+7.00000000, +6.00000000)
765getVerbose(array, weight, sum(weight, mask = weight > 0))
766(+6.00000000, +9.00000000), (+6.00000000, +9.00000000), (+6.00000000, +9.00000000), (+6.00000000, +9.00000000), (+6.00000000, +9.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+7.00000000, +4.00000000), (+7.00000000, +4.00000000), (+7.00000000, +4.00000000), (+7.00000000, +4.00000000), (+2.00000000, +3.00000000), (+2.00000000, +3.00000000), (+2.00000000, +6.00000000), (+2.00000000, +4.00000000), (+7.00000000, +6.00000000), (+7.00000000, +6.00000000), (+7.00000000, +6.00000000), (+7.00000000, +6.00000000)
767array = getRefined(array, weight, skip)
768array
769(+6.00000000, +9.00000000), (+6.00000000, +9.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000), (+8.00000000, +0.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+8.00000000, +7.00000000), (+1.00000000, +4.00000000), (+1.00000000, +4.00000000), (+7.00000000, +4.00000000), (+7.00000000, +4.00000000), (+2.00000000, +3.00000000), (+2.00000000, +4.00000000), (+7.00000000, +6.00000000), (+7.00000000, +6.00000000)
770
771nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
772nsam
773+5
774skip
775+4
776weight = getUnifRand(-1, 9, nsam)
777weight
778-1, -1, +7, -1, +7
779array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
780array
781(+0.00000000, +7.00000000), (+4.00000000, +1.00000000), (+9.00000000, +0.00000000), (+8.00000000, +6.00000000), (+3.00000000, +9.00000000)
782getVerbose(array, weight, sum(weight, mask = weight > 0))
783(+9.00000000, +0.00000000), (+9.00000000, +0.00000000), (+9.00000000, +0.00000000), (+9.00000000, +0.00000000), (+9.00000000, +0.00000000), (+9.00000000, +0.00000000), (+9.00000000, +0.00000000), (+3.00000000, +9.00000000), (+3.00000000, +9.00000000), (+3.00000000, +9.00000000), (+3.00000000, +9.00000000), (+3.00000000, +9.00000000), (+3.00000000, +9.00000000), (+3.00000000, +9.00000000)
784array = getRefined(array, weight, skip)
785array
786(+9.00000000, +0.00000000), (+3.00000000, +9.00000000), (+3.00000000, +9.00000000)
787
788nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
789nsam
790+0
791skip
792+2
793weight = getUnifRand(-1, 9, nsam)
794weight
795
796array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
797array
798
799getVerbose(array, weight, sum(weight, mask = weight > 0))
800
801array = getRefined(array, weight, skip)
802array
803
804
805nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
806nsam
807+1
808skip
809+3
810weight = getUnifRand(-1, 9, nsam)
811weight
812+0
813array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
814array
815(+5.00000000, +3.00000000)
816getVerbose(array, weight, sum(weight, mask = weight > 0))
817
818array = getRefined(array, weight, skip)
819array
820
821
822nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
823nsam
824+4
825skip
826+3
827weight = getUnifRand(-1, 9, nsam)
828weight
829+1, +2, +7, +7
830array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
831array
832(+7.00000000, +4.00000000), (+4.00000000, +0.00000000), (+4.00000000, +7.00000000), (+7.00000000, +0.00000000)
833getVerbose(array, weight, sum(weight, mask = weight > 0))
834(+7.00000000, +4.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +7.00000000), (+4.00000000, +7.00000000), (+4.00000000, +7.00000000), (+4.00000000, +7.00000000), (+4.00000000, +7.00000000), (+4.00000000, +7.00000000), (+4.00000000, +7.00000000), (+7.00000000, +0.00000000), (+7.00000000, +0.00000000), (+7.00000000, +0.00000000), (+7.00000000, +0.00000000), (+7.00000000, +0.00000000), (+7.00000000, +0.00000000), (+7.00000000, +0.00000000)
835array = getRefined(array, weight, skip)
836array
837(+4.00000000, +0.00000000), (+4.00000000, +7.00000000), (+4.00000000, +7.00000000), (+7.00000000, +0.00000000), (+7.00000000, +0.00000000)
838
839nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
840nsam
841+6
842skip
843+1
844weight = getUnifRand(-1, 9, nsam)
845weight
846+3, +4, +4, +8, +2, +5
847array = cmplx(getUnifRand(0, 9, nsam), getUnifRand(0, 9, nsam), TKG)
848array
849(+8.00000000, +1.00000000), (+4.00000000, +0.00000000), (+4.00000000, +5.00000000), (+0.00000000, +9.00000000), (+6.00000000, +1.00000000), (+4.00000000, +2.00000000)
850getVerbose(array, weight, sum(weight, mask = weight > 0))
851(+8.00000000, +1.00000000), (+8.00000000, +1.00000000), (+8.00000000, +1.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +5.00000000), (+4.00000000, +5.00000000), (+4.00000000, +5.00000000), (+4.00000000, +5.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+6.00000000, +1.00000000), (+6.00000000, +1.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000)
852array = getRefined(array, weight, skip)
853array
854(+8.00000000, +1.00000000), (+8.00000000, +1.00000000), (+8.00000000, +1.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +0.00000000), (+4.00000000, +5.00000000), (+4.00000000, +5.00000000), (+4.00000000, +5.00000000), (+4.00000000, +5.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+0.00000000, +9.00000000), (+6.00000000, +1.00000000), (+6.00000000, +1.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000), (+4.00000000, +2.00000000)
855
856nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
857nsam
858+3
859skip
860+3
861weight = getUnifRand(-1, 9, nsam)
862weight
863+5, +5, +5
864array = getUnifRand(0, 9, nsam)
865array
866+0.00000000, +1.00000000, +5.00000000
867getVerbose(array, weight, sum(weight, mask = weight > 0))
868+0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000
869array = getRefined(array, weight, skip)
870array
871+0.00000000, +1.00000000, +1.00000000, +5.00000000, +5.00000000
872
873nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
874nsam
875+4
876skip
877+1
878weight = getUnifRand(-1, 9, nsam)
879weight
880-1, +8, +6, +6
881array = getUnifRand(0, 9, nsam)
882array
883+1.00000000, +5.00000000, +1.00000000, +7.00000000
884getVerbose(array, weight, sum(weight, mask = weight > 0))
885+5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +7.00000000, +7.00000000, +7.00000000, +7.00000000, +7.00000000, +7.00000000
886array = getRefined(array, weight, skip)
887array
888+5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +7.00000000, +7.00000000, +7.00000000, +7.00000000, +7.00000000, +7.00000000
889
890nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
891nsam
892+6
893skip
894+4
895weight = getUnifRand(-1, 9, nsam)
896weight
897+1, -1, +7, +5, +3, +4
898array = getUnifRand(0, 9, nsam)
899array
900+9.00000000, +5.00000000, +1.00000000, +2.00000000, +0.00000000, +6.00000000
901getVerbose(array, weight, sum(weight, mask = weight > 0))
902+9.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +0.00000000, +0.00000000, +0.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000
903array = getRefined(array, weight, skip)
904array
905+1.00000000, +1.00000000, +2.00000000, +0.00000000, +6.00000000
906
907nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
908nsam
909+4
910skip
911+2
912weight = getUnifRand(-1, 9, nsam)
913weight
914+5, +9, +2, +3
915array = getUnifRand(0, 9, nsam)
916array
917+1.00000000, +5.00000000, +6.00000000, +7.00000000
918getVerbose(array, weight, sum(weight, mask = weight > 0))
919+1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +6.00000000, +6.00000000, +7.00000000, +7.00000000, +7.00000000
920array = getRefined(array, weight, skip)
921array
922+1.00000000, +1.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +6.00000000, +7.00000000
923
924nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
925nsam
926+6
927skip
928+4
929weight = getUnifRand(-1, 9, nsam)
930weight
931+0, +6, +4, +5, +5, +4
932array = getUnifRand(0, 9, nsam)
933array
934+6.00000000, +2.00000000, +8.00000000, +5.00000000, +4.00000000, +2.00000000
935getVerbose(array, weight, sum(weight, mask = weight > 0))
936+2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +8.00000000, +8.00000000, +8.00000000, +8.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000
937array = getRefined(array, weight, skip)
938array
939+2.00000000, +8.00000000, +5.00000000, +4.00000000, +4.00000000, +2.00000000
940
941nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
942nsam
943+7
944skip
945+2
946weight = getUnifRand(-1, 9, nsam)
947weight
948+9, +5, +4, +5, +4, +7, +9
949array = getUnifRand(0, 9, nsam)
950array
951+9.00000000, +0.00000000, +4.00000000, +0.00000000, +3.00000000, +4.00000000, +4.00000000
952getVerbose(array, weight, sum(weight, mask = weight > 0))
953+9.00000000, +9.00000000, +9.00000000, +9.00000000, +9.00000000, +9.00000000, +9.00000000, +9.00000000, +9.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +3.00000000, +3.00000000, +3.00000000, +3.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000
954array = getRefined(array, weight, skip)
955array
956+9.00000000, +9.00000000, +9.00000000, +9.00000000, +0.00000000, +0.00000000, +0.00000000, +4.00000000, +4.00000000, +0.00000000, +0.00000000, +3.00000000, +3.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000, +4.00000000
957
958nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
959nsam
960+8
961skip
962+2
963weight = getUnifRand(-1, 9, nsam)
964weight
965+6, -1, +2, +6, +0, +0, +6, +0
966array = getUnifRand(0, 9, nsam)
967array
968+2.00000000, +9.00000000, +5.00000000, +5.00000000, +0.00000000, +6.00000000, +8.00000000, +2.00000000
969getVerbose(array, weight, sum(weight, mask = weight > 0))
970+2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +8.00000000, +8.00000000, +8.00000000, +8.00000000, +8.00000000, +8.00000000
971array = getRefined(array, weight, skip)
972array
973+2.00000000, +2.00000000, +2.00000000, +5.00000000, +5.00000000, +5.00000000, +5.00000000, +8.00000000, +8.00000000, +8.00000000
974
975nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
976nsam
977+0
978skip
979+2
980weight = getUnifRand(-1, 9, nsam)
981weight
982
983array = getUnifRand(0, 9, nsam)
984array
985
986getVerbose(array, weight, sum(weight, mask = weight > 0))
987
988array = getRefined(array, weight, skip)
989array
990
991
992nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
993nsam
994+2
995skip
996+3
997weight = getUnifRand(-1, 9, nsam)
998weight
999+4, +9
1000array = getUnifRand(0, 9, nsam)
1001array
1002+0.00000000, +0.00000000
1003getVerbose(array, weight, sum(weight, mask = weight > 0))
1004+0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000, +0.00000000
1005array = getRefined(array, weight, skip)
1006array
1007+0.00000000, +0.00000000, +0.00000000, +0.00000000
1008
1009nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1010nsam
1011+9
1012skip
1013+3
1014weight = getUnifRand(-1, 9, nsam)
1015weight
1016+3, +8, +2, +0, +5, +7, +0, +2, +6
1017array = getUnifRand(0, 9, nsam)
1018array
1019+9.00000000, +6.00000000, +6.00000000, +7.00000000, +6.00000000, +2.00000000, +1.00000000, +2.00000000, +1.00000000
1020getVerbose(array, weight, sum(weight, mask = weight > 0))
1021+9.00000000, +9.00000000, +9.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +2.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000, +1.00000000
1022array = getRefined(array, weight, skip)
1023array
1024+9.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +6.00000000, +2.00000000, +2.00000000, +2.00000000, +1.00000000, +1.00000000
1025
1026
1027!%%%%%%%%%%%%%%%%%
1028! Refine 2D array.
1029!%%%%%%%%%%%%%%%%%
1030
1031dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1032[dim, ndim, nsam]
1033+2, +0, +5
1034skip
1035+4
1036weight = getUnifRand(-1, 9, nsam)
1037weight
1038+5, +4, +9, +0, +3
1039array = getUnifRand('AA', 'ZZ', ndim, nsam)
1040array
1041getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1042arref = getRefined(array, dim, weight, skip)
1043arref
1044arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1045arref
1046
1047
1048
1049
1050
1051
1052dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1053[dim, ndim, nsam]
1054+2, +1, +7
1055skip
1056+1
1057weight = getUnifRand(-1, 9, nsam)
1058weight
1059+0, +9, +8, +4, -1, +4, +7
1060array = getUnifRand('AA', 'ZZ', ndim, nsam)
1061array
1062"XV", "RE", "DX", "KM", "XK", "DO", "NT"
1063getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1064"RE", "RE", "RE", "RE", "RE", "RE", "RE", "RE", "RE", "DX", "DX", "DX", "DX", "DX", "DX", "DX", "DX", "KM", "KM", "KM", "KM", "DO", "DO", "DO", "DO", "NT", "NT", "NT", "NT", "NT", "NT", "NT"
1065arref = getRefined(array, dim, weight, skip)
1066arref
1067"RE", "RE", "RE", "RE", "RE", "RE", "RE", "RE", "RE", "DX", "DX", "DX", "DX", "DX", "DX", "DX", "DX", "KM", "KM", "KM", "KM", "DO", "DO", "DO", "DO", "NT", "NT", "NT", "NT", "NT", "NT", "NT"
1068arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1069arref
1070"RE"
1071"RE"
1072"RE"
1073"RE"
1074"RE"
1075"RE"
1076"RE"
1077"RE"
1078"RE"
1079"DX"
1080"DX"
1081"DX"
1082"DX"
1083"DX"
1084"DX"
1085"DX"
1086"DX"
1087"KM"
1088"KM"
1089"KM"
1090"KM"
1091"DO"
1092"DO"
1093"DO"
1094"DO"
1095"NT"
1096"NT"
1097"NT"
1098"NT"
1099"NT"
1100"NT"
1101"NT"
1102
1103dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1104[dim, ndim, nsam]
1105+2, +0, +4
1106skip
1107+3
1108weight = getUnifRand(-1, 9, nsam)
1109weight
1110+9, +4, +4, +1
1111array = getUnifRand('AA', 'ZZ', ndim, nsam)
1112array
1113getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1114arref = getRefined(array, dim, weight, skip)
1115arref
1116arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1117arref
1118
1119
1120
1121
1122
1123
1124
1125dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1126[dim, ndim, nsam]
1127+2, +3, +3
1128skip
1129+3
1130weight = getUnifRand(-1, 9, nsam)
1131weight
1132+2, +1, +1
1133array = getUnifRand('AA', 'ZZ', ndim, nsam)
1134array
1135"XF", "FZ", "XQ"
1136"MP", "HH", "GA"
1137"RQ", "KB", "ZY"
1138getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1139"XF", "XF", "FZ", "XQ"
1140"MP", "MP", "HH", "GA"
1141"RQ", "RQ", "KB", "ZY"
1142arref = getRefined(array, dim, weight, skip)
1143arref
1144"FZ"
1145"HH"
1146"KB"
1147arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1148arref
1149"FZ", "HH", "KB"
1150
1151dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1152[dim, ndim, nsam]
1153+2, +2, +6
1154skip
1155+4
1156weight = getUnifRand(-1, 9, nsam)
1157weight
1158+2, +0, +2, +5, -1, +0
1159array = getUnifRand('AA', 'ZZ', ndim, nsam)
1160array
1161"JK", "YP", "CE", "KA", "SL", "GI"
1162"AV", "JC", "BV", "JO", "US", "CM"
1163getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1164"JK", "JK", "CE", "CE", "KA", "KA", "KA", "KA", "KA"
1165"AV", "AV", "BV", "BV", "JO", "JO", "JO", "JO", "JO"
1166arref = getRefined(array, dim, weight, skip)
1167arref
1168"CE", "KA"
1169"BV", "JO"
1170arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1171arref
1172"CE", "BV"
1173"KA", "JO"
1174
1175dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1176[dim, ndim, nsam]
1177+2, +1, +2
1178skip
1179+2
1180weight = getUnifRand(-1, 9, nsam)
1181weight
1182+0, +6
1183array = getUnifRand('AA', 'ZZ', ndim, nsam)
1184array
1185"YM", "LN"
1186getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1187"LN", "LN", "LN", "LN", "LN", "LN"
1188arref = getRefined(array, dim, weight, skip)
1189arref
1190"LN", "LN", "LN"
1191arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1192arref
1193"LN"
1194"LN"
1195"LN"
1196
1197dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1198[dim, ndim, nsam]
1199+2, +1, +2
1200skip
1201+4
1202weight = getUnifRand(-1, 9, nsam)
1203weight
1204+5, +0
1205array = getUnifRand('AA', 'ZZ', ndim, nsam)
1206array
1207"QM", "FY"
1208getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1209"QM", "QM", "QM", "QM", "QM"
1210arref = getRefined(array, dim, weight, skip)
1211arref
1212"QM"
1213arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1214arref
1215"QM"
1216
1217dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1218[dim, ndim, nsam]
1219+2, +2, +1
1220skip
1221+3
1222weight = getUnifRand(-1, 9, nsam)
1223weight
1224+6
1225array = getUnifRand('AA', 'ZZ', ndim, nsam)
1226array
1227"HT"
1228"WK"
1229getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1230"HT", "HT", "HT", "HT", "HT", "HT"
1231"WK", "WK", "WK", "WK", "WK", "WK"
1232arref = getRefined(array, dim, weight, skip)
1233arref
1234"HT", "HT"
1235"WK", "WK"
1236arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1237arref
1238"HT", "WK"
1239"HT", "WK"
1240
1241dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1242[dim, ndim, nsam]
1243+2, +2, +3
1244skip
1245+4
1246weight = getUnifRand(-1, 9, nsam)
1247weight
1248+1, +1, +6
1249array = getUnifRand('AA', 'ZZ', ndim, nsam)
1250array
1251"CD", "SR", "KF"
1252"AK", "IB", "BT"
1253getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1254"CD", "SR", "KF", "KF", "KF", "KF", "KF", "KF"
1255"AK", "IB", "BT", "BT", "BT", "BT", "BT", "BT"
1256arref = getRefined(array, dim, weight, skip)
1257arref
1258"KF", "KF"
1259"BT", "BT"
1260arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1261arref
1262"KF", "BT"
1263"KF", "BT"
1264
1265dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1266[dim, ndim, nsam]
1267+2, +1, +2
1268skip
1269+1
1270weight = getUnifRand(-1, 9, nsam)
1271weight
1272+7, +7
1273array = getUnifRand('AA', 'ZZ', ndim, nsam)
1274array
1275"IK", "FX"
1276getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1277"IK", "IK", "IK", "IK", "IK", "IK", "IK", "FX", "FX", "FX", "FX", "FX", "FX", "FX"
1278arref = getRefined(array, dim, weight, skip)
1279arref
1280"IK", "IK", "IK", "IK", "IK", "IK", "IK", "FX", "FX", "FX", "FX", "FX", "FX", "FX"
1281arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1282arref
1283"IK"
1284"IK"
1285"IK"
1286"IK"
1287"IK"
1288"IK"
1289"IK"
1290"FX"
1291"FX"
1292"FX"
1293"FX"
1294"FX"
1295"FX"
1296"FX"
1297
1298dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1299[dim, ndim, nsam]
1300+2, +2, +1
1301skip
1302+3
1303weight = getUnifRand(-1, 9, nsam)
1304weight
1305+1
1306array = getUnifRand(0, 9, ndim, nsam)
1307array
1308+3
1309+4
1310getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1311+3
1312+4
1313arref = getRefined(array, dim, weight, skip)
1314arref
1315
1316
1317arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1318arref
1319
1320dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1321[dim, ndim, nsam]
1322+2, +2, +6
1323skip
1324+3
1325weight = getUnifRand(-1, 9, nsam)
1326weight
1327+4, +9, +8, +6, +3, +8
1328array = getUnifRand(0, 9, ndim, nsam)
1329array
1330+7, +9, +6, +9, +8, +5
1331+0, +3, +3, +1, +5, +5
1332getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1333+7, +7, +7, +7, +9, +9, +9, +9, +9, +9, +9, +9, +9, +6, +6, +6, +6, +6, +6, +6, +6, +9, +9, +9, +9, +9, +9, +8, +8, +8, +5, +5, +5, +5, +5, +5, +5, +5
1334+0, +0, +0, +0, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +3, +1, +1, +1, +1, +1, +1, +5, +5, +5, +5, +5, +5, +5, +5, +5, +5, +5
1335arref = getRefined(array, dim, weight, skip)
1336arref
1337+7, +9, +9, +9, +6, +6, +6, +9, +9, +8, +5, +5
1338+0, +3, +3, +3, +3, +3, +3, +1, +1, +5, +5, +5
1339arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1340arref
1341+7, +0
1342+9, +3
1343+9, +3
1344+9, +3
1345+6, +3
1346+6, +3
1347+6, +3
1348+9, +1
1349+9, +1
1350+8, +5
1351+5, +5
1352+5, +5
1353
1354dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1355[dim, ndim, nsam]
1356+2, +1, +1
1357skip
1358+4
1359weight = getUnifRand(-1, 9, nsam)
1360weight
1361+9
1362array = getUnifRand(0, 9, ndim, nsam)
1363array
1364+2
1365getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1366+2, +2, +2, +2, +2, +2, +2, +2, +2
1367arref = getRefined(array, dim, weight, skip)
1368arref
1369+2, +2
1370arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1371arref
1372+2
1373+2
1374
1375dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1376[dim, ndim, nsam]
1377+2, +1, +8
1378skip
1379+4
1380weight = getUnifRand(-1, 9, nsam)
1381weight
1382+4, +4, -1, +1, +9, +0, +3, +4
1383array = getUnifRand(0, 9, ndim, nsam)
1384array
1385+0, +8, +1, +2, +8, +3, +6, +5
1386getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1387+0, +0, +0, +0, +8, +8, +8, +8, +2, +8, +8, +8, +8, +8, +8, +8, +8, +8, +6, +6, +6, +5, +5, +5, +5
1388arref = getRefined(array, dim, weight, skip)
1389arref
1390+0, +8, +8, +8, +6, +5
1391arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1392arref
1393+0
1394+8
1395+8
1396+8
1397+6
1398+5
1399
1400dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1401[dim, ndim, nsam]
1402+2, +2, +1
1403skip
1404+1
1405weight = getUnifRand(-1, 9, nsam)
1406weight
1407+3
1408array = getUnifRand(0, 9, ndim, nsam)
1409array
1410+6
1411+0
1412getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1413+6, +6, +6
1414+0, +0, +0
1415arref = getRefined(array, dim, weight, skip)
1416arref
1417+6, +6, +6
1418+0, +0, +0
1419arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1420arref
1421+6, +0
1422+6, +0
1423+6, +0
1424
1425dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1426[dim, ndim, nsam]
1427+2, +3, +7
1428skip
1429+3
1430weight = getUnifRand(-1, 9, nsam)
1431weight
1432+8, -1, +7, +8, +6, -1, +2
1433array = getUnifRand(0, 9, ndim, nsam)
1434array
1435+1, +2, +6, +7, +9, +0, +6
1436+3, +3, +2, +0, +9, +3, +6
1437+4, +9, +8, +0, +8, +4, +7
1438getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1439+1, +1, +1, +1, +1, +1, +1, +1, +6, +6, +6, +6, +6, +6, +6, +7, +7, +7, +7, +7, +7, +7, +7, +9, +9, +9, +9, +9, +9, +6, +6
1440+3, +3, +3, +3, +3, +3, +3, +3, +2, +2, +2, +2, +2, +2, +2, +0, +0, +0, +0, +0, +0, +0, +0, +9, +9, +9, +9, +9, +9, +6, +6
1441+4, +4, +4, +4, +4, +4, +4, +4, +8, +8, +8, +8, +8, +8, +8, +0, +0, +0, +0, +0, +0, +0, +0, +8, +8, +8, +8, +8, +8, +7, +7
1442arref = getRefined(array, dim, weight, skip)
1443arref
1444+1, +1, +6, +6, +6, +7, +7, +9, +9, +6
1445+3, +3, +2, +2, +2, +0, +0, +9, +9, +6
1446+4, +4, +8, +8, +8, +0, +0, +8, +8, +7
1447arref = getRefined(transpose(array), 3_IK - dim, weight, skip)
1448arref
1449+1, +3, +4
1450+1, +3, +4
1451+6, +2, +8
1452+6, +2, +8
1453+6, +2, +8
1454+7, +0, +0
1455+7, +0, +0
1456+9, +9, +8
1457+9, +9, +8
1458+6, +6, +7
1459
1460dim = 2; ndim = merge(0, getUnifRand(1, 3), isHead(.1)); nsam = getUnifRand(0, 9); skip = getUnifRand(1, 4)
1461[dim, ndim, nsam]
1462+2, +1, +1
1463skip
1464+2
1465weight = getUnifRand(-1, 9, nsam)
1466weight
1467+6
1468array = getUnifRand(0, 9, ndim, nsam)
1469array
1470+6
1471getVerbose(array, weight, sum(weight, mask = weight > 0), dim)
1472+6, +6, +6, +6, +6, +6
1473arref = getRefined(array, dim, weight, skip)