Reputation: 373
I'm a complete newbie to Lisp-Stat, and I started working through the tutorial at https://lisp-stat.dev/docs/tutorials/basics, but when I type
(standard-deviation purchases)
(with purchases defined as a list of integers as in the tutorial), I get the error:
#<STANDARD-GENERIC-FUNCTION DISTRIBUTIONS:STANDARD-DEVIATION (1)> when called with the arguments ...
after which it repeats the list referenced by purchases. It gives me the same thing if I use some floating-point numbers as well.
I'm using SBCL in SLIME on Ubuntu 22.04.
Any help would be greatly appreciated! Many thanks!
Upvotes: 5
Views: 85
Reputation: 786
This is a documentation bug, now fixed. Use standard-deviation
to obtain the standard deviation of a distribution, and sd
to obtain the standard deviation of a sample. We should probably consolidate these two into a single generic function.
Also, although you can get an answer from any channel, for doc bugs and tutorial specific things it's probably easier to raise a github issue. You can do that from within the documentation using the links at the top right of the page. That way they'll be tracked.
Upvotes: 6