3 ms·
Is there in general a formula for fudging statistics in the direction of bias? I.e., 90% becomes 99% as 10% becomes 1%? Was there a general algorithm you used
by ooqr 10y ago
Is there in general a formula for fudging statistics in the direction of bias? I.e., 90% becomes 99% as 10% becomes 1%? Was there a general algorithm you used. I'd be interested in hearing the technical details.
- emptybits 10y agoWhat you describe (non-linear) would probably have been superior but in my youth and inexperience over 15 years ago (and pressed with time and code-size constraints) I am sure I did nothing more than a scalar, maybe clamped with a C macro MAX() or MIN(). Sorry to disappoint; sometimes game AI and sim work just needs to be "good enough" and ... most importantly, needs to ship on time (on shelves, yes shelves, X weeks before opening day of baseball season) with zero bugs (no online patches in those days). So there is a certain satisfaction in that. :-)
- ooqr 10y agoThanks for the reply. I came up with: f(x) = (sin((pi * x) - (pi / 2)) + 1) / 2 where x is between 0 and 1 I'm a collector of randomness functions for games. Weighted, gaussian, linear, etc. This sinusoidal randomness will be handy! Thanks for the inspiration.