Commit Graph

70 Commits

Author SHA1 Message Date
Wirawan Purwanto
70ae2812c3 * wpylib.math.fitting.fit_func_base: changed default fitting method to leastsq. 2015-06-04 16:06:21 -04:00
Wirawan Purwanto
a244c49256 * Bug fixes and documentation update. 2015-05-28 17:22:46 -04:00
Wirawan Purwanto
64691c0425 * Change to new way to obtain the 'C' fitting parameters. 2015-05-28 17:21:24 -04:00
Wirawan Purwanto
78c638a371 * Bug fixes and documentation update. 2015-05-28 17:20:34 -04:00
Wirawan Purwanto
39dddbd51d * Added module: wpylib.math.fitting.stochastic.
NOTE: Only imported verbatimly from Cr2_analysis_cbs.py CVS rev 1.143.
2015-05-28 12:04:54 -04:00
Wirawan Purwanto
1a537af020 * Dialect correction: "x == None" -> "x is None". 2015-05-22 23:59:01 -04:00
Wirawan Purwanto
e46fcec698 * Imported more recent function fitting facility from Cr2 project. 2015-05-21 11:34:03 -04:00
Wirawan Purwanto
e37110b08b * Added more support for legacy 'rannyi' RNG from our Fortran codes,
including one from normal gaussian PDF.
2015-05-21 11:30:19 -04:00
Wirawan Purwanto
82a55b940a * wpylib.math.fitting: Imported fit_func_base from Cr2 project.
* Added documentation on fitting methods.
2015-05-20 11:47:38 -04:00
Wirawan Purwanto
4111dc2da7 * Moved Poly_base & friends to wpylib.math.fitting.funcs_poly. 2015-05-20 10:35:48 -04:00
Wirawan Purwanto
f9cdb33e32 * Added "LDC" layout (C row-major, lower diagonal storage).
* Added reference mapping generator (and sample output for 5x5)
  for each layout.
2015-05-14 16:07:16 -04:00
Wirawan Purwanto
b4883c4ca9 * Added shortcut to modified Gram Schmidt (modgs) -> wpylib.math.linalg.modgs. 2015-04-03 16:08:53 -04:00
Wirawan Purwanto
10047b26f9 * Module wpylib.math.linalg.gram_schmidt to orthonormalize a set of
columns vectors.
2015-04-01 15:46:48 -04:00
Wirawan Purwanto
8a5a11971f * Experimental support for BLAS for matrix multiplication.
Not enabled by default, yet.
2014-11-05 22:50:49 -05:00
Wirawan Purwanto
d841380864 * Added class wpylib.math.stats.avg.weight_stats for weighted statistical
analysis.
2014-09-04 17:44:50 -04:00
Wirawan Purwanto
597398a34b * Added missing function (rms). 2014-05-29 13:55:05 -04:00
Wirawan Purwanto
bb3db2667a * Module array_stat: Added study_sparsity() and print_histogram(),
adapted from V2b_inspect research module.
2014-04-17 16:42:36 -04:00
Wirawan Purwanto
aaa06dc531 * Added rdiff() function to calculate element-wise relative difference of
two arrays.
2014-04-17 13:33:59 -04:00
Wirawan Purwanto
a347ae6d47 * New module: wpylib.math.stats.array_stats, for studying statistics of
an array (e.g., sparsity, difference, etc).
2014-04-07 12:25:33 -04:00
Wirawan Purwanto
3b0a8af1aa * Added MathWarning for mathematics-related warning messages. 2014-03-28 14:29:10 -04:00
Wirawan Purwanto
04e78ade1d * Added extra debugging statements. 2014-02-24 16:06:40 -05:00
Wirawan Purwanto
b043fb3cdf * fit_func: Added support for lmfit-based minimization.
Tested minimally in the Cr2_analysis_cbs.py workbench (routine:
  Test_MC_FPTZ_20140206).
2014-02-07 18:25:22 -05:00
Wirawan Purwanto
a33ad3c766 * Introduced a much faster way (and simpler) to compute jackknife averages. 2013-12-11 16:25:29 -05:00
Wirawan Purwanto
4e2b2c66c2 * Added wpylib.math.stats.jackknife1, initial implementation of delete-one
jackknife resampling method.

  This module also contains a hack for weighted average
  (warning: the theory is not established yet, at least I have not seen
  it).
2013-12-11 00:15:24 -05:00
Wirawan Purwanto
f0ba6f4068 * wpylib.math: Added complex_polar(). 2013-12-09 17:27:44 -05:00
Wirawan Purwanto
869aa91109 * fit_func(): Allow non-(numpy.ndarray) args for x, y, dy.
* Documentation update.
2013-10-17 13:49:50 -04:00
Wirawan Purwanto
579be3e18a * errorbar: Added "lazy" string evaluation to speed up errorbar algebra. 2013-10-02 15:32:46 -04:00
Wirawan Purwanto
ed1242dc66 * Added "lazy string printout" which will speed up errorbar algebra--i.e.
we only need to evaluate the string representation when
  the string printout isrequired.
2013-10-02 14:30:55 -04:00
Wirawan Purwanto
c8aad2e2f8 * Added facility for smoothed approximating spline instead of "exact"
interpolation.
2013-09-17 18:00:08 -04:00
Wirawan Purwanto
06fa307e84 * spline_2d: Use public scipy API functions. 2013-09-17 17:18:29 -04:00
Wirawan Purwanto
564d1f4364 * wpylib.math.fitting.fit_func: Added support for weight (or y uncertainty).
* For `leastsq' fit method, also introduced 'xerr' output (in outfmt=0)
  as the error estimate of the fitted parameters.
2013-08-19 15:43:49 -04:00
Wirawan Purwanto
37b0939671 * Documentation clarification. 2013-08-19 15:43:19 -04:00
Wirawan Purwanto
1421cf3bc5 * wpylib.math.fitting.fit_func: Allow Guess argument to override
machine-generated guess.
* Add 'funcalls' data key to the leastsq complete output to conform to the
  fmin-style output.
2013-08-19 10:50:54 -04:00
Wirawan Purwanto
2907b2ca77 * Set lcg48 default seed_index for user's reference 2013-08-19 10:11:09 -04:00
Wirawan Purwanto
42fdcc5253 * Added new module wpylib.math.random and its submodule (rng_lcg48).
The LCG48 generator is primarily for testing algorithms involving random
  numbers.
2013-08-14 15:29:26 -04:00
Wirawan Purwanto
e485cabbe8 * wpylib.math.fitting.fit_func: Added optional Funct_hook argument to
be called (for debugging purposes) every time "the" Funct function
  is called.
2013-08-13 01:05:38 -04:00
Wirawan Purwanto
cdad14e034 * Added BFGS minimization. 2013-08-09 16:51:38 -04:00
Wirawan Purwanto
9de8407dd9 * Added Test_3(). 2012-10-15 17:25:06 -04:00
Wirawan Purwanto
a0eb82ed2b * Mute debug printing. 2012-10-15 16:59:35 -04:00
Wirawan Purwanto
5b213b0ee7 * Little syntax optimization. 2012-10-15 16:45:37 -04:00
Wirawan Purwanto
414643ecde * Added testcase wpylib.math.fitting.linear.Test_2() against numpy.polyfit(). 2012-10-15 16:35:12 -04:00
Wirawan Purwanto
cb8124f699 * Provide uncertainty of both a and b fit parameters. 2012-10-15 16:12:37 -04:00
Wirawan Purwanto
87763d6e57 * wpylib.math.fitting.linear: for linear fit methods.
First method: linregr2d_SZ() from Shiwei's email in 2006.
2012-10-15 16:02:41 -04:00
Wirawan Purwanto
908a4e0682 * Rebase fit_result on result_base. 2012-10-15 16:01:46 -04:00
Wirawan Purwanto
348c204699 * Change wpylib.math.fitting module from a file into a subdirectory. 2012-10-15 15:16:02 -04:00
Wirawan Purwanto
332d9ae240 * wpylib.math: added choose() function. 2012-08-24 16:32:33 -04:00
Wirawan Purwanto
17d242213d * Added some useful functions from my pw2g_bench_MnO.py scriptlet collection:
- wpylib.math.roundup()
  - wpylib.shell_tools.dirname2()

* file_exists_nonempty() is moved to wpylib.shell_tools.
2012-07-25 09:40:37 -04:00
Wirawan Purwanto
050e2414ef * Added faster LDdec1 for 1-based indexing.
Tested through N=1000.
2012-01-26 10:46:55 -05:00
Wirawan Purwanto
d04ea8cbea * Completing jskip formula for LD that is analogous to the jskip formula for
UD matrix format.
2012-01-25 17:07:50 -05:00
Wirawan Purwanto
93a89d2606 * Created array indexer for "upper diagonal" indexing mode.
Apparently I was able to create the non-iterative version of UDdec (1-based
  indices).
2012-01-24 17:32:39 -05:00