Sponsored Content
Full Discussion: [Solved] Data manipulation
Top Forums Shell Programming and Scripting [Solved] Data manipulation Post 302892001 by CarloM on Monday 10th of March 2014 08:45:11 AM
Old 03-10-2014
You want the highest field 2 value for each unique field 1? (If so, your output data appears to be missing a few rows, e.g. for 335550)

You could do something like:
Code:
awk '{ if ($2 > rates[$1]) { rates[$1]=$2 } } END { for (i in rates) { print i OFS rates[i] } }' aaaa.csv

Note: This does not preserve the ordering or the fixed-width formatting.
This User Gave Thanks to CarloM For This Post:
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Data Manipulation

Hello I am currently having problems in mapulating a certain file which contains vaious data. Belos is a sample content Event=<3190> Client IP=<151.111.11.143> DNS=<abc.sbc.com> TransCount=<139> Client IP=<150.222.133.163> DNS=<xyz.yuu.com> TransCount=<3734> Event=<3120> Client... (11 Replies)
Discussion started by: khestoi
11 Replies

2. Shell Programming and Scripting

Tricky data manipulation...

Hi everyone.. I am new here, hello.. I hope this doesn't come across to you folks as a stupid question, I'm somewhat new to scripting :) I'm seeking some help in finding a way to manipulate data output for every two characters - example: numbers.lst contains the following output:... (3 Replies)
Discussion started by: explicit
3 Replies

3. Shell Programming and Scripting

Data manipulation from one file

HI all i have a file consisting of following numbers 0000 0000 0000 0000 0000 1010 0000 0100 0000 0000 0000 1111 0000 1010 0000 0100 (3 Replies)
Discussion started by: vaibhavkorde
3 Replies

4. UNIX for Dummies Questions & Answers

[Solved] Column manipulation

Hi Everyone, I was wondering if someone could help me to transform my data into a format I need. Here is an example of what my data looks like E F G H A 1 2 3 4 B 5 6 7 8 C 9 1 2 3 D 4 5 6 7 and this is what I would need it to look like: AE 1 BE 5 CE 9 DE 4 AF 2 BF 6 CF 1 (6 Replies)
Discussion started by: zajtat
6 Replies

5. UNIX for Dummies Questions & Answers

Script for data manipulation

Hi all! my first post here, so mods -- if this should ideally be in the scripts section, please move there. Thanks! I have data in the following format: key1:value1 key2:value2 key3:value3 A B C D key1:value4 key2:value5 key3:value6 A1 B1 key1: ... and so on I want an output... (2 Replies)
Discussion started by: gnat01
2 Replies

6. UNIX for Dummies Questions & Answers

[Solved] Text manipulation help

Hello Unix.com How can I sort from a large email list only the emails that finish with .ca domain? cat <list> | grep "\.ca\b" >> <new list> isnt working perfectly. Any tips? Best regards, Galford D. Weller (2 Replies)
Discussion started by: galford
2 Replies

7. Shell Programming and Scripting

[Solved] awk manipulation of sequentially named files

Hello, I am a very novice user of awk, I have a set of files named file001, file002, file003, file004, etc., each contains four fields (columns of data) separated each by a uneven number of spaces. I want to substitute those spaces by a TAB, so I am using this line of awk script: awk -v OFS="\t"... (4 Replies)
Discussion started by: jaldo0805
4 Replies

8. UNIX for Dummies Questions & Answers

Data manipulation

Hallo Team, I need to manipulate existing data file. Have a look at current data and expected data: Current Data: 27873517141 27873540000 27873515109 27873517140 27873540001 27873540000 27873501343 27873540000 27873517140 27873511292 27873645989 27873540000 27873540000... (7 Replies)
Discussion started by: kekanap
7 Replies

9. UNIX for Dummies Questions & Answers

Data Manipulation

Dear Sir, I have file input RGR001|108.28|-2.86489|100-120|RANGGAR RGR002|108.071|-2.69028|80-100|RANNGAR RGR003|108.168|-2.97053|50-80|RANNGAR RGR007|108.192722222|-2.766138889|0-50|RANGGARI want to create files by joining each rows with each rows below Output as below ... (4 Replies)
Discussion started by: radius
4 Replies

10. Shell Programming and Scripting

Data manipulation, Please help..

Hello, I have a huge set of data that needs to be reformatted. Here is a simple example to explain the process. I have number n=5 and a input with many numbers separated with comma: ... (11 Replies)
Discussion started by: liuzhencc
11 Replies
ath(7D) 							      Devices								   ath(7D)

NAME
ath - Atheros AR52xx 802.11b/g wireless NIC driver DESCRIPTION
The ath 802.11b/g wireless NIC driver is a multi-threaded, loadable, clonable, GLDv3-based STREAMS driver for the Atheros AR52xx (AR5210/5211/5212) chipset-based wireless NIC. The ath driver functions include controller initialization, wireless 802.11b/g infrastructure network connection, WEP, frame transmit and receive, and promiscuous and multi-cast support. DRIVER CONFIGURATION
The ath driver performs auto-negotiation to determine the data rates and mode. Supported 802.11b data rates (Mbits/sec.) are 1, 2, 5.5 and 11. Supported 802.11g data rates (Mbits/sec.) are 1, 2, 5.5, 11, 6, 9, 12, 18, 24, 36, 48 and 54. The ath driver supports only BSS networks (also known as "ap" or "infrastructure" networks) and the "open" (or "opensystem") authentica- tion type. Only WEP encryption is currently supported. Configuration and administration can be performed through the dladm(1M) or wificonfig(1M) utilities. FILES
/dev/ath* Special character device. /kernel/drv/ath 32-bit ELF kernel module (x86). /kernel/drv/amd64/ath 64-bit ELF kernel module (x86). ATTRIBUTES
See attributes(5) for descriptions of the following attributes: +-----------------------------+-----------------------------+ | ATTRIBUTE TYPE | ATTRIBUTE VALUE | +-----------------------------+-----------------------------+ |Architecture |x86 | +-----------------------------+-----------------------------+ SEE ALSO
dladm(1M), wificonfig(1M), gld(7D) ANSI/IEEE Std 802.11- Standard for Wireless LAN Technology, 1999. IEEE Std 802.11a- Standard for Wireless LAN Technology-Rev. A, 2003 IEEE Std 802.11b - Standard for Wireless LAN Technology-Rev.B, 2003 IEEE Std 802.11g-- Standard for Wireless LAN Technology - Rev. G, 2003 SunOS 5.11 14 Nov 2006 ath(7D)
All times are GMT -4. The time now is 07:19 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy