Replace Pioneer Home
All Examples
Free Download
all
Advanced search and replace
Replace text in multiple files
Regular expression replace
Batch file rename
Batch download
Text file parser
Text file splitter
Html text generator
Search replace binary
Random word generator
Count and statistics
Character encoding
Bin Hex Oct Dec converter
Text generator
Text sort
Text merge
Text data calculation
RSS: Replace Pioneer Examples
662.Text data calculation -- How to multiply the first column with the rest of columns in one file?
User:
Lynne -- 2010-11-22
<< 661
663 >>
Hits:
3298
Type:
Text data calculation
Search all
Text data calculation
examples
Description:
How to multiply column in one file?
Input Sample:
Input Sample:
1 2 4 6..
2 2 5 8..
3 4 6 9..
There are 1000 columns in one file.
Output Sample:
Output Sample:
1*2 1*4 1*6..
2*2 2*5 2*8..
3*4 3*6 3*9..
Answer:
Hint: You need to
Download and install "Replace Pioneer"
on windows platform to finish following steps.
1. ctrl-o open source text file
2. ctrl-h open 'replace' window
* set 'replace unit' to 'Line'
* set 'replace with pattern' to:
join(' ',map{calc($match[1]*$match[$_]);}(2..$max-1))\n
3. click 'replace', done!
4. ctrl-s save to file.
Screenshot 1: Replace_Window
Similar Examples:
How to multiply the fifth column by 10 in a text file?
(74%)
How to duplicate column A by the number of times in column B in csv file?
(67%)
How to multiply column in one file with multiple columns in another?
(66%)
How to merge text by first column and calculate average for rest columns?
(61%)
How to delete the 4th column from text files with 8 columns?
(61%)
How to replace the 4th column if the 5th column is 0?
(60%)
How to remove/delete first column for multiple files?
(60%)
How to delete last column in a csv file?
(58%)
Check Demo of
Text data calculation
Keywords:
multiply
max
calculation
first column
calcu
calculat
columns
map
data
calc
multiply columns of text
multiply column of text
multiply column data
multiply in text file
multiply file
first columns
text to columns open source
calculation in text file