06-19-2011
Post desired output for that sample please.
This User Gave Thanks to bartus11 For This Post:
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
Hi
Is there any command or a trick that can take me to a specifed line number in unix .
Suppose i have a file with 2000 lines and i would like to go to line number 1899 and then print out the contents of the line.
regards
Hrishy (2 Replies)
Discussion started by: xiamin
2 Replies
2. Shell Programming and Scripting
I trying to extract certain text from a csv file and then placing it into another csv file, but having problems getting the data to placed in one line with tab separated fields.
Basically would like to have text sent to interfaces.csv in one line seperated by tabs. As it currently places files... (6 Replies)
Discussion started by: 00000008
6 Replies
3. Shell Programming and Scripting
Hi,
I need convert a dump file in the following format : (please note that line numbers are provided for easy look)
Original file:
1 2007-10-2482.90 No trade 0 0.00 100000.00
2 100000.00
3 0.00
4 HOLD
5 2007-10-2589.75 Bought 1114 1114 100000.00 0.00
... (5 Replies)
Discussion started by: sabyasm
5 Replies
4. Shell Programming and Scripting
OS=HP-UX ksh
The following works, except I want to include the <start> and <end> in the output.
awk -F '<start>' 'BEGIN{RS="<end>"; OFS="\n"; ORS=""} {print $2} somefile.log'
The following work in bash but not in ksh
sed -n '/^<start>/,/^<end>/{/LABEL$/!p}' somefile.log (4 Replies)
Discussion started by: Ikon
4 Replies
5. Shell Programming and Scripting
I am creating some documentation that includes a list of packages that are to be installed for a Debian Server.
This is a single line and I would like to sort the list of packages alphabetically.
Using a small example of the packages, the best I could come up with was as follows:
I create... (1 Reply)
Discussion started by: jelloir
1 Replies
6. Shell Programming and Scripting
Hello.
I have a file (old.txt) that I need to copy into another file (new.txt).
Each line on old.txt ends with CR/LF but the position of CR/LF varies from one record to another.
I need to copy each line of record to new.txt and move CR/LF in pos 165.
Can I use awk to achieve this? How?... (8 Replies)
Discussion started by: udelalv
8 Replies
7. Shell Programming and Scripting
I have a file with different directories in it. I would need to move one line within the file to the end of the list. Also not there could be blank line in the middle of it. Example
/vol/fs1
/vol/fs2
/vol/fs3
/vol/fs4
/vol/fs5
/vol/fs6
/vol/fs7
So I would need /vol/fs2... (3 Replies)
Discussion started by: bombcan
3 Replies
8. Shell Programming and Scripting
Hello everyone,
I'm struggling with this command:
awk '!/^\+/{ORS=FS}/^\+/{ORS=RS}1' file1 > file2
What I want to do is to move any line that starts with the + sign 1 up, so its the continuation of the previous.
The above command is messing the whole output, can you please let me know... (8 Replies)
Discussion started by: demmel
8 Replies
9. UNIX for Dummies Questions & Answers
I have a file in which each line is the name of another file. Is there a way to serve them to the command line? For example, if the file contains
file1.txt
file2.txt
file3.txt
...
file9.txt
is there a way to insert them in the command as a batch?
If I ran a command like
grep... (4 Replies)
Discussion started by: wbport
4 Replies
10. Shell Programming and Scripting
Team,
would like to know if it is possibe to move line above.after TEST pattern match
#cat file1
data1
data2
ok
Test
data1
ok
Test
data2
Test
Output:
Test (8 Replies)
Discussion started by: kenshinhimura
8 Replies
SRCONV(1) The Canonical Csound Reference SRCONV(1)
NAME
srconv - Converts the sample rate of an audio file. .
DESCRIPTION
Converts the sample rate of an audio file at sample rate Rin to a sample rate of Rout. Optionally the ratio (Rin / Rout) may be linearly
time-varying according to a set of (time, ratio) pairs in an auxiliary file.
SYNTAX
srconv [flags] infile
INITIALIZATION
Flags:
o -P num = pitch transposition ratio (srate / r) [don't specify both P and r]
o -P num = pitch transposition ratio (srate / r) [don't specify both P and r]
o -Q num =quality factor (1, 2, 3, or 4: default = 2)
o -i filnam = auxiliary breakpoints file (no breakpoint by default. i.e. No ratio change)
o -r num = output sample rate (must be specified)
o -o fnam = sound output filename
o -A = create an AIFF format output soundfile
o -J = create an IRCAM format output soundfile
o -W = create a WAV format output soundfile
o -h = no header on output soundfile
o -c = 8-bit signed_char sound samples
o -a = alaw sound samples
o -8 = 8-bit unsigned_char sound samples
o -u = ulaw sound samples
o -s = short_int sound samples
o -l = long_int sound samples
o -f = float sound samples
o -r N = orchestra srate override
o -K = Do not generate PEAK chunks
o -R = continually rewrite header while writing soundfile (WAV/AIFF)
o -H# = print a heartbeat style 1, 2 or 3 at each soundfile write
o -N = notify (ring the bell) when score or miditrack is done
o -- fnam = log output to file
This program performs arbitrary sample-rate conversion with high fidelity. The method is to step through the input at the desired sampling
increment, and to compute the output points as appropriately weighted averages of the surrounding input points. There are two cases to
consider:
1. sample rates are in a small-integer ratio - weights are obtained from table.
2. sample rates are in a large-integer ratio - weights are linearly interpolated from table.
Calculate increment: if decimating, then window is impulse response of low-pass filter with cutoff frequency at half of output sample rate;
if interpolating, then window is impulse response of lowpass filter with cutoff frequency at half of input sample rate.
CREDITS
Author: Mark Dolson
August 26, 1989
Author: John ffitch
December 30, 2000
AUTHORS
Barry Vercoe
MIT Media Lab
Author.
Dan Ellis
MIT Media Lab,
Cambridge
Massachussetts
Author.
COPYRIGHT
5.07 06/23/2009 SRCONV(1)