From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/27390 Path: news.gmane.org!not-for-mail From: "Mojca Miklavec" Newsgroups: gmane.comp.tex.context Subject: Feature request: Creating tables from (tab-separated) values Date: Sat, 22 Apr 2006 04:02:57 +0200 Message-ID: <6faad9f00604211902m5c88d10apcd5c208f1825f51c@mail.gmail.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1145717717 3279 80.91.229.2 (22 Apr 2006 14:55:17 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 22 Apr 2006 14:55:17 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Sat Apr 22 16:55:12 2006 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by ciao.gmane.org with esmtp (Exim 4.43) id 1FXJVt-0004aU-BP for gctc-ntg-context-518@m.gmane.org; Sat, 22 Apr 2006 16:55:09 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id D29E612795; Sat, 22 Apr 2006 16:55:08 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 30724-01-3; Sat, 22 Apr 2006 16:55:00 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 4D7521278D; Sat, 22 Apr 2006 16:55:00 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id A47B91278D for ; Sat, 22 Apr 2006 16:54:58 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 30724-01-2 for ; Sat, 22 Apr 2006 16:54:56 +0200 (CEST) Original-Received: from nproxy.gmail.com (nproxy.gmail.com [64.233.182.190]) by ronja.ntg.nl (Postfix) with SMTP id 7D6F51278A for ; Sat, 22 Apr 2006 16:54:56 +0200 (CEST) Original-Received: by nproxy.gmail.com with SMTP id x37so537912nfc for ; Sat, 22 Apr 2006 07:54:56 -0700 (PDT) Original-Received: by 10.48.211.17 with SMTP id j17mr1759189nfg; Fri, 21 Apr 2006 19:02:57 -0700 (PDT) Original-Received: by 10.48.223.20 with HTTP; Fri, 21 Apr 2006 19:02:57 -0700 (PDT) Original-To: "mailing list for ConTeXt users" Content-Disposition: inline X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:27390 Archived-At: Hello, This idea described below was partially inspired by "gnuplot contemptations", but mainly because writing tables with both LaTeX & ConTeXt is too complex in most cases. Natural tables are great since they offer anough flexibility to do "just about anything" with tables, but many tables are still simple "m values in n rows" and for those it's an annoying task to write those "\NC"s, "\eTR\bTR"s, ... even if it's just a matter of writing a script to transform the values to a suitable form. Christopher Creutzig has sent an interesting solution to the mailing list some time ago (see http://wiki.contextgarden.net/TABLE#Creating_tables_from_CSV_data_.28Comma_Separated_Values.29) and since then I've been thinking about a similar, slightly more powerful solution which could make table-typesetiting easier. I don't have enough skills to implement it, but here are some properties listed that such a solution should have. In case anyone finds this little project doable ... It would solve quite some headaches. - [very important] a possibility to define own macros, so that it would be easy to print any type of tables (natural tables, TaBlEs, ... or whatever form that could possibly come to someone's mind); for example \def\MyDef#1#2{\bTR\bTD#1\eTD\bTD#2\eTD\eTR}; the "machinery behind" would only have to "feed" these macros properly according - [important] possible to separate the data with different characters: tab, comma, multiple spaces, ampersand (&), ... - [very useful] a possibility to read the data from a block (\start...\stop...) or from a file; it would be handly to be able to use the same data file for making a plot and for printing the data into a table - [useful] possibility to ignore lines starting with '#' (optional; usually these are comments) - [not crucial] if comma (,) is separating the data, a possibility to escape it - [useful] a possibility to select which rows (columns) to print (for example rows "1-3,8-last" or "even", ...) - [optional, but still useful] replacing decimal points with commas - [optional] if the table was supposed to have 4 colums and only 2 are available, ignore/fill with empty arguments (don't panic with unnecessary errors) - [with luaTeX in mind] calculating sums of rows & columns & other Excel-like calculations & references accross tables ;) - well, that one wasn't meant seriously. Thanks a lot, Mojca