
<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.rajkumar.in/index.php?action=history&amp;feed=atom&amp;title=Transpose</id>
	<title>Transpose - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://www.rajkumar.in/index.php?action=history&amp;feed=atom&amp;title=Transpose"/>
	<link rel="alternate" type="text/html" href="https://www.rajkumar.in/index.php?title=Transpose&amp;action=history"/>
	<updated>2026-07-09T20:11:19Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.46.0</generator>
	<entry>
		<id>https://www.rajkumar.in/index.php?title=Transpose&amp;diff=1414&amp;oldid=prev</id>
		<title>Raj: Created page with &#039;  &lt;source lang=perl&gt;  #! /usr/bin/perl  ################################################################################################### # #	 AUTHOR:  Ryan M. Castillo #    VE…&#039;</title>
		<link rel="alternate" type="text/html" href="https://www.rajkumar.in/index.php?title=Transpose&amp;diff=1414&amp;oldid=prev"/>
		<updated>2010-01-31T08:27:34Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;#039;  &amp;lt;source lang=perl&amp;gt;  #! /usr/bin/perl  ################################################################################################### # #	 AUTHOR:  Ryan M. Castillo #    VE…&amp;#039;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;&lt;br /&gt;
&lt;br /&gt;
&amp;lt;source lang=perl&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#! /usr/bin/perl&lt;br /&gt;
&lt;br /&gt;
###################################################################################################&lt;br /&gt;
#&lt;br /&gt;
#	 AUTHOR:  Ryan M. Castillo&lt;br /&gt;
#    VERSION: Version 1 (04 January 2007)&lt;br /&gt;
#    PURPOSE: Transpose a comma seperated values file&lt;br /&gt;
#    INPUT: user specified file&lt;br /&gt;
#    OUTPUT FILES: tr_&amp;lt;Name of File&amp;gt;&lt;br /&gt;
#&lt;br /&gt;
# Copyright Notice:&lt;br /&gt;
#&lt;br /&gt;
# Copyright 2007 Ryan Castillo&lt;br /&gt;
#&lt;br /&gt;
#  This program is free software; you can redistribute it and/or &lt;br /&gt;
#  modify it under the terms of the GNU General Public License as &lt;br /&gt;
#  published by the Free Software Foundation; either version 2 of &lt;br /&gt;
#  the License, or any later version.&lt;br /&gt;
#&lt;br /&gt;
#  This program is distributed in the hope that it will be useful, &lt;br /&gt;
#  but WITHOUT ANY WARRANTY; without even the implied warranty of &lt;br /&gt;
#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. &lt;br /&gt;
#&lt;br /&gt;
#  See the GNU General Public License for more details.&lt;br /&gt;
#&lt;br /&gt;
#  You should have received a copy of the GNU General Public License &lt;br /&gt;
#  along with this program; if not, write to the&lt;br /&gt;
#         Free Software Foundation, Inc., &lt;br /&gt;
#         59 Temple Place, Suite 330, Boston, MA  &lt;br /&gt;
#         02111-1307  USA &lt;br /&gt;
#  or visit http://www.gnu.org/copyleft/gpl.html&lt;br /&gt;
#&lt;br /&gt;
###################################################################################################&lt;br /&gt;
&lt;br /&gt;
my $input_path = $ARGV[0];&lt;br /&gt;
&lt;br /&gt;
#### OPEN OUR INPUT FILE&lt;br /&gt;
open INPUT_FILE, &amp;quot;&amp;lt;$input_path&amp;quot;&lt;br /&gt;
	or die &amp;quot;Something&amp;#039;s wrong with the input file!\n&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
my $line = &amp;lt;INPUT_FILE&amp;gt;;						# holds the current line from the input file&lt;br /&gt;
my @AoA;										# array that will be an array of arrays&lt;br /&gt;
&lt;br /&gt;
while (defined $line){&lt;br /&gt;
	chomp $line;&lt;br /&gt;
	push @AoA, [split /\,/, $line];&lt;br /&gt;
	$line = &amp;lt;INPUT_FILE&amp;gt;;&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
close INPUT_FILE;&lt;br /&gt;
&lt;br /&gt;
#### OPEN OUR OUTPUT FILE&lt;br /&gt;
my $output_path = &amp;quot;tr_$input_path&amp;quot;;&lt;br /&gt;
open RESULT, &amp;quot;&amp;gt;$output_path&amp;quot; &lt;br /&gt;
	or die &amp;quot;Can&amp;#039;t open $output_path: $!\n&amp;quot;;&lt;br /&gt;
&lt;br /&gt;
for $i (0 ... $#{$AoA[0]}){&lt;br /&gt;
	for $j (0 ... $#AoA){&lt;br /&gt;
		if ($j == $#AoA){&lt;br /&gt;
			print RESULT &amp;quot;$AoA[$j][$i]\n&amp;quot;;&lt;br /&gt;
		}&lt;br /&gt;
		elsif ($AoA[$j][$i] eq &amp;quot;&amp;quot;){&lt;br /&gt;
			print RESULT &amp;quot;\n&amp;quot;;&lt;br /&gt;
			last;&lt;br /&gt;
			}&lt;br /&gt;
		else{&lt;br /&gt;
			print RESULT &amp;quot;$AoA[$j][$i]\,&amp;quot;;&lt;br /&gt;
		}&lt;br /&gt;
	}&lt;br /&gt;
	if ($AoA[$j][$i] eq &amp;quot;&amp;quot;) {last;}&lt;br /&gt;
}&lt;br /&gt;
close RESULT;&lt;br /&gt;
&amp;lt;/source&amp;gt;&lt;br /&gt;
[[Category:Bioinformatics]]&lt;/div&gt;</summary>
		<author><name>Raj</name></author>
	</entry>
</feed>