From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8121 invoked by alias); 27 Oct 2002 18:50:18 -0000 Mailing-List: contact gcc-help-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-help-owner@gcc.gnu.org Received: (qmail 8078 invoked from network); 27 Oct 2002 18:50:17 -0000 Received: from unknown (HELO web40405.mail.yahoo.com) (66.218.78.102) by sources.redhat.com with SMTP; 27 Oct 2002 18:50:17 -0000 Message-ID: <20021027185017.11389.qmail@web40405.mail.yahoo.com> Received: from [199.243.24.106] by web40405.mail.yahoo.com via HTTP; Sun, 27 Oct 2002 10:50:17 PST Date: Sun, 27 Oct 2002 10:50:00 -0000 From: AS225 Subject: Transpose/merge To: gcc-help@gcc.gnu.org MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-SW-Source: 2002-10/txt/msg00335.txt.bz2 Hi all, I am not that much skilled in C/C++ programming, but I am eager to learn more about it. I have a problem to manipulate the following data set. I hope that I may get a help from you guys! I am looking for an algorithm that transpose(merge) a data set by a variable. The data set is a two dimensional x(m,n). If the the value of the first column is equal to the value of the previous row (m,1 =m-1,1) then merge the variables of ( m, 2-n) to the first row. May be an example of a data set explain in a better way. obs v1 v2 v3 1 11 12 13 1 21 22 23 2 22 23 24 3 44 45 46 3 55 54 56 3 66 65 66 The transposed(merged) data file would look like 1 11 12 13 21 22 23 2 22 23 24 3 44 45 46 55 54 56 66 65 66 Any help is highly appreciated in advance Ashe __________________________________________________ Do you Yahoo!? Y! Web Hosting - Let the expert host your web site http://webhosting.yahoo.com/