You're right, using the addons is better. I just got used to using the
built-in functions out of habit.
Henry Rich
On 8/8/2012 7:42 PM, Ian Clark wrote:
@Henry Given the choice between the "package" or the "addon" (eg for
'stats'), which is the one to use: the package or the addon?
I'd plump for the "addon", because you can keep it up-to-date using
pacman. But of course you have to opt to install it using pacman,
whereas the "package" gets installed when J is first installed. Are
there maybe other things to consider here?
AFAICS there's no good reason not to install *all* the addons using
pacman, and keep them up to date the same way. They don't take up much
room, don't take long to download, and don't get in your way if you
don't use them. Also, downloading an addon will automatically install
any (updated) labs that come with it. Am I overlooking something?
...Apart from the possibility of people (like me) releasing a buggy
version of an addon? :-)
Mind you, there's a gotcha lurking here. If you enter:
open 'stats'
open 'stats/base/random'
in the first case you get the "package", in the second you get the
"addon". You have to be alert and watch for the path that appears in
the window header.
In j602, the verb: "open" uses a system noun: PUBLIC_j_ to decide
where to look for 'stats'.
AFAIK, PUBLIC_j_ is created by the script:
~system/extras/config/scripts.ijs . But I don't know whether pacman
updates this script, ever. From the date on the .ijs file, I suspect
it can.
Comments? (Like: what's different in j701?)
On Wed, Aug 8, 2012 at 11:55 PM, Henry Rich <[email protected]> wrote:
The verbs are defined in the 'stats' package.
To see what they are, I do
open 'stats'
that is a 3-line verb. The last line looks promising, so I do
open '~system\packages\stats\statdist.ijs'
That brings up the header, which shows that
normalrand
is what you are looking for. You can scroll down to see the header of the
verb.
Then,
load 'stats'
to load the scripts, and
normalrand 5
0.351534 _1.1435 _0.097765 0.378719 0.543748
Henry Rich
On 8/8/2012 6:37 PM, Owen Marschall wrote:
Hi everyone,
Quick question:
How do you generate normally distributed random numbers? I remember one of
the labs showed me how, but I've tried every possible combination of
abbreviations of "normal" and "random," yet nothing's working. I'm guessing
the lab must have loaded some package I forgot about. What package is this?
I've looked through the labs and can't find it.
Also, does anyone know how to make the J dictionary work on a mac? My
computer opens it with gedit for some reason and won't compile it.
Thanks,
Owen
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm