After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 144717 - Any way to add positive skew to randnorm?
Any way to add positive skew to randnorm?
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: Analytics
1.2.x
Other Linux
: Normal enhancement
: ---
Assigned To: Jody Goldberg
Jody Goldberg
Depends on:
Blocks:
 
 
Reported: 2004-06-21 00:39 UTC by garetholoughlin
Modified: 2009-10-11 17:15 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description garetholoughlin 2004-06-21 00:39:33 UTC
Can't seem to figure out if this is possible.  I still want something that goes
negative so the other pdfs aren't adequate.

I'm using gnumeric 1.2.8 on the latest FC2
Comment 1 Andreas J. Guelzow 2004-06-23 15:46:59 UTC
If you add a positive skew to randnorm then it isn't normal anymore. The usual
procedure to get a differently shaped random distribution is to take randnorm
and transform the result before using it. 
Comment 2 Andreas J. Guelzow 2004-06-24 17:05:14 UTC
If you are more specific in which kind of pdf you would like to see added we can
surely accomodate you. THis request to date is unfortunately much too vague.
Comment 3 garetholoughlin 2004-06-26 16:47:50 UTC
Go this link and click on "show the density function"
http://azzalini.stat.unipd.it/SN/plot-SN1.html
Something like that.

More info on it available here:
http://azzalini.stat.unipd.it/SN/
Comment 4 Andreas J. Guelzow 2004-06-26 17:26:15 UTC
Thanks, I guess you are looking for a random number generator for the univariate
skew-normal distribution. I would think we can add that one.
Comment 5 garetholoughlin 2004-06-26 17:47:45 UTC
Yes.  I should have been clearer earlier.  Guess I was thinking it would have
been an option in randnorm but can see that you might want it separate altogether.
Comment 6 Andreas J. Guelzow 2009-10-10 20:28:39 UTC
We should probably also include the density function, cumulative distribution function etc of the skew normal (and skew t etc. distributions.) THe code for these are available in R (licensed via GPL 2 or later):

http://r-forge.r-project.org/plugins/scmsvn/viewcvs.php/pkg/fGarch/inst/unitTests/runit4A.R?rev=1871&root=rmetrics&view=markup

I am wondering whetehr we can use the "generate" script in fn-r to include this code. Morten?
Comment 7 Andreas J. Guelzow 2009-10-10 20:34:13 UTC
Sorry, I copied the wrong link. It should have been:
http://r-forge.r-project.org/plugins/scmsvn/viewcvs.php/*checkout*/pkg/fGarch/R/dist-snorm.R?rev=4174&root=rmetrics
Comment 8 Andreas J. Guelzow 2009-10-10 20:35:52 UTC
And that should have been LGPL
Comment 9 Morten Welinder 2009-10-10 22:51:07 UTC
Translating that to C is probably less effort to do by hand than using
one of my hacky scripts.

Also, the numerical quality of that code is -- at a first look -- less
than the quality of the C code.
Comment 10 Andreas J. Guelzow 2009-10-11 17:15:16 UTC
RANDSNORM and RANDSTDIST have been added. They will be in 1.9.15.