Can anyone help me out with formatting a large dataset in certain form, i.e.
The final form should look like this
31 0.00 0.00 0.94 0.00 0.00 0.00 0.06 0.00 0.00 4.76 1 1968
29 120.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 2 1968
Where the...
I have a large series of text in 3 columns and its needs to be formatted to single row of every 12 rows of the columns; example data set.
1867 1 6.40
1867 2 5.90
1867 3 4.70
1867 4 3.70
1867 5 2.50
1867 6 2.20
1867 7 2.40
1867 8 3.20
1867 9 4.30
1867 10 5.20
1867 11 5.90
1867 12 6.90
1868 1...
I am trying to subtract two matrix which are large file, into one matrix. The matrix for example as follows:
Matrix 1
4 5 7 8
6 9 12 5
3 1 0 2
Matrix 2
7 9 2 0
1 3 6 2
3 5 8 1
Subtract result will be:
-3 -4 5 8
5 6 6 3
0 -4 -8 1
Any help will eb gratly appreciated.
Thanks.
I am using gawk now. It works. I think, when the starting row number is greater than the ending row number, it does not output correctly.
Anyhow, it is a great code. I am giving you all the stars that i can give.
I am trying to figure out, how to extract data points from a large matrix (m by n) file. I want to extract data along an inclined straight line, along any row and column of a matrix. Example below is what I want to achieve:
Matrix Example
20 21 22 290 46
7 12 18 13 12
16...
Dear Friends,
I have a question regarding extracting some data from a series of matrix files (large files) along any cooordinate lines. Here is an example as what I meant:
5 8 12 7
9 3 8 6 File1.dat
4 5 7 4
3 6 4 4
5 8 7 3 File2.dat
2 0...
Hello,
Can anyone help me out to write an output in matrix format in AWK95, where my input file is in the form of, example:
2,3,1,0,A,0,1,42
2,4,1,0,B,0,1,42
3,1,1,0,C,0,1,42
3,2,1,0,D,0,1,42
3,3,1,0,E,0,1,42
4,6,1,0,F,0,1,42
4,7,1,0,G,0,1,42
My output file would be in the form:
A B
C D...
I have a large text file with date and time. I want to get rid of the date and only have the time.
Example data:
5/31/2006 10:21:00
5/31/2006 10:21:01
5/31/2006 10:21:02
5/31/2006 10:21:03
5/31/2006 10:21:04
5/31/2006 10:21:05
5/31/2006 10:21:06
My final data set should look like this...
I have a series of datasets called, fi.dat, f2.dat,f3.dat, etc.
Example of one of the dataset is given below:
f1.dat
A B C D E
F G H I
J K L
f2.dat
0.1 0.2. 0.4
A B C D
1 2 3 4
My final dataset should look like:
final.dat
A B C D E
F G H I
J K L
0.1 0.2. 0.4
A B C D
1 2 3 4
What's...
Hi Feherke,
Congratulations! Its works now. It was my mistake, to mistakenly name the output file name as the input file.
I am giving you a star. Thanks for lots of help. Truely appreciate. This site is great!
Thanks.
Hi Feherke,
As you suggested, I tried the process:, the generator.awk program is such:
BEGIN {
for (i=1;i<=3;i++) print "awk95 -f test.awk f" i ".dat > c:\temp\test\\f" i ".dat"
}
when I run in the DOS prompt,
C:\temp\test> awk95 -f generator.awk > commands.bat
it generates the...
Hi feherke,
When I try the code, with 3 files, it do not provide any output, it just run
BEGIN {
for (i=1;i<=3;i++) print "awk95 -f test.awk f" i ".dat > output_dir/f" i ".dat"
}
Hi PHV,
Congratulations! It works. Your perseverance works. I am giving you few stars. I have many such files, and I want to automate it, what should I do. I have close to 500 such files. My files are written in a sequencing format, such as f1.dat, f2.dat, etc.
Thanks.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.