Re: Information-Theory functions.
Paul Kienzle <[email protected]> Thu, 28 Sep 2006 21:55:20 -0400
| Newsgroups | gmane.comp.gnu.octave.sources |
|---|---|
| Message-ID | <[email protected]> |
On Sep 28, 2006, at 7:55 PM, Muthiah Annamalai wrote: > Hi there, > I have my first cut functions on basic functions in > Information Theory; the package is a nice candidate > for inclusion into Octave-forge. If Paul or David > can approve it, I can gohead and fix it according > to Octave-forge specifications. 1) If you structure the initial comments as follows then it won't show up in the help string. ## Copyright (C) ... ## ## This program is free software ... ## ... ## normal function help ## ... 2) If you put tests of the following form after your function they will be automatically run on install: %!assert(expr, expected, tol) See 'help test' for details. 3) You will need to use the new package directory structure and metadata files. 4) texinfo is the usual format for documentation (and someday even I might start using it 8-) 5) Your 'see also' help needs to be in the same comment block as the rest of the help. 6) Are you sure the info-theory.m file needs to have copies of all your functions? Also, it probably shouldn't have an extension since it is available on the octave command line. 7) In mutualinformation, rather than: idx_rng = 1:cols tVal = XY(i,idx_rng)./(X(idx_rng)*Y(i)) You can write: tVal = XY(i,:)./(X*Y(i)) Also, it seems to have one too many end statements. 8) Rather than size(X)(2) you can write size(X,2) I haven't checked whether these functions duplicate existing matlab functions. - Paul