10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
input
A1 B1 A2 B2
0 0 1 1
1 0 0 1
0 1 1 0
1 1 1 1
Output
label A1 B1 A2 B2
A1 2 1 1 2
B1 1 2 2 1
A2 1 2 3 2
B2 2 1 2 3
Ex:
The number of times that A1 and B1 row values are both 1 should be printed as output.
The last row of A1 and B1 in the input match by having 1 in both... (4 Replies)
Discussion started by: quincyjones
4 Replies
2. Shell Programming and Scripting
I have a file that contains 2 columns tag,pos
cat input_file
tag pos
atg 10
ata 16
agt 15
agg 19
atg 17
agg 14
I have used following command to sort the file based on second column
sort -k 2 input_file
tag pos
atg 10
agg 14
agt 15
ata 16
agg 19
atg 17 (2 Replies)
Discussion started by: raj_k
2 Replies
3. Shell Programming and Scripting
Hi Friends,
I have an input matrix file like this
Col1 Col2 Col3 Col4
R1 1 2 3 4
R2 4 5 6 7
R3 5 6 7 8
I would like to consider only the numeric values without touching the column header and the row header.
I looked up on the forum's search, and I found this. But, I donno how to... (3 Replies)
Discussion started by: jacobs.smith
3 Replies
4. Shell Programming and Scripting
Hi All,
I do have a file with many lines (rows) and it is space delimited. For example: I have a file named SR345_pl.txt. If I open it in an editor, it looks like this:
adfr A2 0.9345
dtgr/2 A2 0.876
fgh/3 A2 023.76
fghe/4 A2 2345
bnhy/1 A3 3456
bhy A3 0.9876
phy A5 0.987
kdrt A5... (9 Replies)
Discussion started by: Lucky Ali
9 Replies
5. Programming
Dear All
I would like to convert columns to matrix
For example my data looks like this
D2 0 D2 0 1.0
D2 0 D2 1 0.308
D2 0 D2 2 0.554
D2 0 D2 3 0.287
D2 0 D2 4 0.633
D2 0 D2 5 0.341
D2 0 D2 6 0.665
D2 0 D2 7 0.698
D2 0 D2 8 0.625
D2 0 D2 9 0.429
D2 0 D2 10 0.698
D2 0 D2 11... (7 Replies)
Discussion started by: bala06
7 Replies
6. Shell Programming and Scripting
Hi, every one. I have two files ,one is in matrix like this, one is a list with the same data as the matrix.
AB AE AC AD AA AF
SA 3 4 5 6 4 6
SC 5 7 2 8 4 3
SD 4 6 5 3 8 3
SE 45 ... (5 Replies)
Discussion started by: xshang
5 Replies
7. Shell Programming and Scripting
Hello folks
I have a txt file of information about journal articles from different fields. I need to convert this information into a format that is easier for computers to manipulate for some research that I'm doing on how articles are cited. The file has some header information and then details... (8 Replies)
Discussion started by: ksk
8 Replies
8. Shell Programming and Scripting
Hi everyone
I am very new at awk but think that that might be the best strategy for this. I have a matrix very similar to a correlation matrix and in practical terms I need to convert it into a list containing the values from the matrix (one value per line) with the first field of the line (row... (5 Replies)
Discussion started by: stonemonkey
5 Replies
9. Shell Programming and Scripting
Hi all,
Here is a scim sample.bin.user file
a string1 0
a string2 0
a string3 63
b string4 126
c string5 315
d string6 0
e string7 63
e string8 126
f string9 0
I like to convert this into a dict.tab file to be compiled by the ... (4 Replies)
Discussion started by: hk008
4 Replies
10. Programming
Hi power user,
I have this type of data (distance list):
file1
A B 10
B C 20
C D 50I want output like this
# A B C D
A 0 10 30 80
B 10 0 20 70
C 30 20 0 50
D 80 70 50 0 Which is a distance matrix
I have tried... (0 Replies)
Discussion started by: anjas
0 Replies