Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Selecting highest value within a range Post 302740659 by markymarkg123 on Thursday 6th of December 2012 02:27:36 PM
Old 12-06-2012
Good start! Thank you. Your code is cool, but it does not select the highest peak (line 5). It picks line 4 because it is the first to exceed 5000. Can it be written to pick line 5 (the biggest) and then to eliminate the line before 5 (line 4) and the line after 5 (line 6)?
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

sort with highest wc

Hi :) I'm a unix beginner and i've recently got an assignment to write up a script to print the most common IP address that made requests from a webserver. I'm really lost in this one...and if someone could pls tell me where to start i'll be really greatful ! thanx (1 Reply)
Discussion started by: ymf
1 Replies

2. Shell Programming and Scripting

Selecting files between a user inputed date range

Hi all! I'm working on a KSH script to select files between a user inputed date range (stored in a variable) and then move them and unzip them. I'm stuck at how to get the files between the user inputed date range selected. Any help would be greatly appreciated! The files are as such: ... (6 Replies)
Discussion started by: kelldan
6 Replies

3. UNIX for Dummies Questions & Answers

Printing highest value from one column

Hi, I have a file that looks like this: s6 98 s6 91 s6 56 s5 32 s5 10 s5 4 So what I want to do is print only the highest value for each value in the column: So the file will look like this: s6 98 s5 32 Thanks (4 Replies)
Discussion started by: phil_heath
4 Replies

4. Shell Programming and Scripting

print range between two patterns if it contains a pattern within the range

I want to print between the range two patterns if a particular pattern is present in between the two patterns. I am new to Unix. Any help would be greatly appreciated. e.g. Pattern1 Bombay Calcutta Delhi Pattern2 Pattern1 Patna Madras Gwalior Delhi Pattern2 Pattern1... (2 Replies)
Discussion started by: joyan321
2 Replies

5. Shell Programming and Scripting

Extract the highest number out

Hi Gurus, I've using HPUX B.11.23 U ia64 with shell = sh. I've been having some problem get the highest number of this script. Actually I wanted to get the highest number from this listing (TEST123 data and based on this highest number, there will be email being sent out. For example,... (6 Replies)
Discussion started by: superHonda123
6 Replies

6. Shell Programming and Scripting

Selecting a range of Lines

Hi All, Is there a way to get a range of lines from a file??? I want to search through a set of scripts and need to select the group of lines which do the FTP. Say, Line1 Line2 ftp SERVER user UNAME PASS send FILE_TO_BE_SENT close Line3 Line4 Line5 ftp SERVER1 user USER1 PASS1... (6 Replies)
Discussion started by: beinthemiddle
6 Replies

7. Shell Programming and Scripting

Finding the highest value(in negative)

Hi all, I have a simple problem. I have given an example of the problem below. There are 4 space-delimited columns. 2655 96 IA -0.8179 2655 96 IA -0.9144 2655 96 CPU -0.4275 2655 96 RMA -0.3407 2655 96 IA -0.9373 2655 96 ... (2 Replies)
Discussion started by: jaysean
2 Replies

8. Shell Programming and Scripting

Printing highest value from a list

Hi all, I'm trying to get the item with the maximum value, and was wondering if someone can help me with it. Heres my input file: apples 15 books 15 books 17 pens 12 pens 15 umbrella 13Here's what my output file should look like: apples 15 books 17 pens 15 umbrella 13 Can... (2 Replies)
Discussion started by: r4v3n
2 Replies

9. Shell Programming and Scripting

Selecting lowest and highest values in columns 1 and 2, based on subsets in column 3

Hi, I have a file with the following columns: 361459 447394 CHL1 290282 290282 CHL1 361459 447394 CHL1 361459 447394 CHL1 178352861 178363529 AGA 178352861 178363529 AGA 178363657 178363657 AGA Essentially, using CHL1 as an example. For any line that has CHL1 in... (2 Replies)
Discussion started by: hubleo
2 Replies

10. Shell Programming and Scripting

Highest value matrix parsing

Hi All I do have a matrix in the following format a_2 a_3 s_4 t_6 b 0 0.9 0.004 0 c 0 0 1 0 d 0 0.98 0 0 e 0.0023 0.96 0 0.0034 I have thousands of rows I would like to parse the maximum value in each of the row and out put that highest value along the column header of... (2 Replies)
Discussion started by: Kanja
2 Replies
GPIV_ERRVEC(1)						      General Commands Manual						    GPIV_ERRVEC(1)

NAME
gpiv_errvec - Searches erroneous vectors in a PIV data file and substitutes with new values. SYNOPSIS
gpiv_errvec [-a] [-b ] [-g][-h] [-h | --help] [-i | --image_type S] [-n N] [--no_b ] [-p | --print] [-r N] [-s N] [-t F] [-u | --surround] [-v | --version] [filename] < stdin > stdout DESCRIPTION
gpiv_errvec searches erroneous outliers in a PIV data stream and substitutes with new values, if possible, i.e. if (the majority) of its surroundings are non-erroneous. Evaluation of erroneous vectors is done by looking up the Signal to Noise Ratio (SNR) value in the PIV data file or by calculating the median residu of the vector with its surroundings. A new displacement is obtained by the mean value of the surrounding values or by the location of the next higher peak in the covariance function. PIV data validation is not needed anymore while this is now done during image interrogation with gpiv_rr. Though using gpiv_errvec will not harm. The configuration parameters (containing the VALID key) may be overruled by the command line options, as explained below. Options -a Automatic threshold; calculates threshold value from residu histogram. -b Calculate statistics of the median residues and print a histogram of N bins. -g Graphical visualization of residu statistics with gnuplot (needs filename). -b is not required as this option will be set automati- cally. -h | --help On-line help. -i | --image_type S Image type or format to be used if particle displacements will have to be re-estimated at the next highest correlation peak. S may be png, tif, gif, bmp, pgm, r or gpi. Default: png. -n N Defines number of histogram of bins N for -b or -a --no_b N suppresses printing median residu histogram -p | --print Print parameters, command line options and eventually used input and output filenames to stdout. The output is identic of file- name.par, in case filename is used. -r N Erroneous vector determined by SNR of the correlation function (N = 0), median residu (N = 1) or normalized median (N = 2), i.e. the ratio between median residu with current datapoint included and between median residu of surroundigs (with datapoint excluded). -s N Substitution of the erroneous vectors by (N = 0) nothing, the local mean from the surrounding values (N = 1), median (N = 2) or next highest covariance peak (N = 3, needs filename). -t F Threshold value F of SNR or median residu to determine validity of particle displacement. -u | --surround Odd number representing the surrounding grid points to be used for local mean and median values. -v | --version Print version information on standard output, then exit successfully. filename Full name of PIV data file for input. Substitutes stdin and stdout. Output will be written to filename.erv.piv. The parameters will be written or appended to filename.par and may be used for future use by including them in ./gpivrc. If particle displacements will have to be re-estimated at the next highest correlation peak, filename is required. SEE ALSO
gpivtools AUTHOR
Gerber Van der Graaf BUGS
The program has been tested for artificial generated DPIV images. So far, no serious bugs have been found. 23 May 2005 GPIV_ERRVEC(1)
All times are GMT -4. The time now is 06:04 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy