From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nick Dokos Newsgroups: gmane.emacs.help Subject: Re: why are there [v e c t o r s] in Lisp? Date: Mon, 19 Oct 2015 12:33:40 -0400 Message-ID: <87mvvebyxn.fsf@alphaville.usersys.redhat.com> References: <87oafzpqfj.fsf@debian.uxu> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1445272467 3928 80.91.229.3 (19 Oct 2015 16:34:27 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 19 Oct 2015 16:34:27 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Oct 19 18:34:17 2015 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZoDO4-0005y3-Mj for geh-help-gnu-emacs@m.gmane.org; Mon, 19 Oct 2015 18:34:16 +0200 Original-Received: from localhost ([::1]:40930 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZoDO3-0003VS-Vo for geh-help-gnu-emacs@m.gmane.org; Mon, 19 Oct 2015 12:34:15 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43457) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZoDNr-0003V7-RG for help-gnu-emacs@gnu.org; Mon, 19 Oct 2015 12:34:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZoDNn-0002Rq-R5 for help-gnu-emacs@gnu.org; Mon, 19 Oct 2015 12:34:03 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:39484) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZoDNn-0002Rc-Ka for help-gnu-emacs@gnu.org; Mon, 19 Oct 2015 12:33:59 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1ZoDNi-0005gB-VD for help-gnu-emacs@gnu.org; Mon, 19 Oct 2015 18:33:55 +0200 Original-Received: from nat-pool-bos-t.redhat.com ([66.187.233.206]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 19 Oct 2015 18:33:54 +0200 Original-Received: from ndokos by nat-pool-bos-t.redhat.com with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Mon, 19 Oct 2015 18:33:54 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 29 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: nat-pool-bos-t.redhat.com User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) Cancel-Lock: sha1:iZDew2cShXkUwectCcfvDyjEc4E= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:107757 Archived-At: Jude DaShiell writes: > vectors are how elisp got used to write functions that do statistics I > think. The vmean() function being one example and vmedian() being > another. Unfortunately org-mode hasn't got a vmode() function to go > along with those two which is why I use datamash to calculate my > helath statistics. > You mean *Calc* does not have a vmode() function: org spreadsheets piggy-back on calc for vmean() (a.k.a. calc-vector-mean) and vmedian() (a.k.a. calc-vector-median). And indeed Calc does not define a vmode() function. I think - without any inside knowledge - that's because the mode can be very dependent on the distribution and different circumstances would require different definitions (e.g. a multimodal distribution with a bunch of maxima, not all the same: is the mode the global maximum or is it the list of all the maxima? or perhaps a list of a subset of the maxima - and in that case, which ones? Part of the difficulty would be classifying a given empirical distribution - i.e. a vector of values - as one or another of these multimodal distributions, so that Calc would know which definition to use. But your *particular* case might not require such classification (you know what kind of distribution you have), in which case a specialised vmode() can be written - but it would not apply in general). -- Nick