Sponsored Content
Top Forums UNIX for Beginners Questions & Answers sed to replace / between the two numbers Post 303037987 by RudiC on Tuesday 20th of August 2019 08:15:00 AM
Old 08-20-2019
You're close. Try
Code:
sed -r 's/([0-9])\/([0-9])/\1\t\2/' file
view    pz19a0c0    1000T_J_3MoDw9DSLh1ZsCubdua-LKOQmbtiVgkIsiMbSiwF467?sessionId=15451401994597121249
view    pz19a0c0    100086X67pR0MwzWnhhSO6sAEoxeFMyhh-IIbUCCdxicaQM4FC9?sessionId=154514019945971212494898
view/cart       pz19a0c0    100086X67pR0MwzWnhhSO6sAEoxeFMyhh-IIbUCCdxicaQM4FC9?sessionId=15451401994597121249

This User Gave Thanks to RudiC For This Post:
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Script to replace numbers by string

Hi! I need the following script: - All numbers in a filename (0-9) have to be replace by a String ("Zero"-"Nine") - The script has to go through all the files in the current directory and has to replace the numbers as described above... I have no idea how to do this... Thanks! Michael (5 Replies)
Discussion started by: Michi21609
5 Replies

2. UNIX for Dummies Questions & Answers

Replace US numbers with European numbers

hey, I have a file with numbers in US notation (1,000,000.00) as well as european notation (1.000.000,00) i want all the numbers to be in european notation. the numbers are in a text file, so to prevent that the regex also changes the commas in a sentence/text i thought of: sed 's/,/\./'... (2 Replies)
Discussion started by: FOBoy
2 Replies

3. Shell Programming and Scripting

How to replace multiple numbers?

hello everyone i searched the net and i could not find script for this request. i believe sed command will do it but i'm not sure about how. my file contains thousands of records, the following is sample: BEGIN ASX15001 BEGIN ASX15000000500020101230 ASX18001020070002010123... (10 Replies)
Discussion started by: neemoze
10 Replies

4. Shell Programming and Scripting

replace numbers in records

hello every one I have file with following records begin ASX120016719 ASX190006729 ASX153406729 ASX190406759 ASX180006739 end for each record there is ASX word then 9 digits after it (NO spaces included) what i want is to : 1- skip ASX 2-skip first 2 digits after ASX word... (16 Replies)
Discussion started by: neemoze
16 Replies

5. Shell Programming and Scripting

sed&awk: replace lines with counting numbers

Dear board, (I am trying to post this the 3rd time, seems there's some conflicts with my firefox with this forum, now use IE) ------ yes, I have searched the forum, but seems my ? is too complicated. ------------origianl file --------------- \storage\qweq\ertert\ertert\3452\&234\test.rec... (4 Replies)
Discussion started by: oUo
4 Replies

6. Shell Programming and Scripting

using sed to find and replace multiple numbers

I have looked around and there are several examples of how to use sed, but I don't think any of them help me very much with what I am trying to do. I have a text file like this.... 1! SRCNAM = 00001 ! 1! X = 50.0000, 0.0000,... (10 Replies)
Discussion started by: mercury.int
10 Replies

7. UNIX for Dummies Questions & Answers

Selective Replacements: Using sed or awk to replace letters with numbers in a very specific way

Hello all. I am a beginner UNIX user who is using UNIX to work on a bioinformatics project for my university. I have a bit of a complicated issue in trying to use sed (or awk) to "find and replace" bases (letters) in a genetics data spreadsheet (converted to a text file, can be either... (3 Replies)
Discussion started by: Mince
3 Replies

8. UNIX for Dummies Questions & Answers

Sed/awk to find negative numbers and replace with 1?

Greetings. I have a three column file, and there are some numbers in the second column that are <1. However I need all numbers to be positive, thus need to replace all those numbers with just one. I feel like there must be a simple way to use awk to find these numbers and sed to replace but can't... (5 Replies)
Discussion started by: Twinklefingers
5 Replies

9. UNIX for Dummies Questions & Answers

How can I replace the lines that start with a star and replace it with numbers start from 1?

I need to replace the (*) in the fist of a list with numbers using sed for example > this file contain a list * linux * computers * labs * questions to >>>> this file contain a list 1. linux 2. computers 3. labs 4. questions (7 Replies)
Discussion started by: aalbazie
7 Replies

10. UNIX for Dummies Questions & Answers

Replace groups into sequential numbers

I have a file that looks like this: n1 1 n2 1 n3 1 n4 3 n4 3 n2 5 n2 5 n2 5 n2 5 n3 5 n3 5 n4 6 n7 6 that is a name followed be a descriptive number. I want to make these numbers sequential starting from 0 but without changing the "neighbours" each name belongs to. So the above... (3 Replies)
Discussion started by: FelipeAd
3 Replies
VWRIGHT(1)						      General Commands Manual							VWRIGHT(1)

NAME
vwright - normalize a RADIANCE view, shift it to the right SYNOPSIS
vwright [ view options ] distance vwright [ view options ] name DESCRIPTION
In the first form, vwright shifts a RADIANCE view the specified distance to the right, putting out a complete set of view parameters in a single line on the standard output. This utility is most often used to compute a right-eyed view from a left-eye view for stereo imaging. If no options are specified on the command line, vwright reads a view from its standard input. The distance given is in world coordinate units. A negative value indicates a shift to the left rather than the right. The second form substitutes a name prefix in place of the shift distance, and produces constant assignments on the standard output suitable for passing directly to rcalc(1). For a given prefix N, the constant names are as follows: Nt: view type ('v'==1,'l'==2,'a'==3,'h'==4,'c'==5,'s'==6) Npx: view point x value Npy: view point y value Npz: view point z value Ndx: view direction x value (normalized) Ndy: view direction y value (normalized) Ndz: view direction z value (normalized) Nd: view focal distance Nux: view up vector x value (normalized) Nuy: view up vector y value (normalized) Nuz: view up vector z value (normalized) Nh: view horizontal size Nv: view vertical size Ns: view shift Nl: view lift No: view fore clipping distance Na: view aft clipping distance Nhx: derived horizontal image vector x value (normalized) Nhy: derived horizontal image vector y value (normalized) Nhz: derived horizontal image vector z value (normalized) Nhn: derived horizontal image vector multiplier Nvx: derived vertical image vector x value (normalized) Nvy: derived vertical image vector y value (normalized) Nvz: derived vertical image vector z value (normalized) Nvn: derived vertical image vector multiplier EXAMPLES
To start rpict(1) on a view .06 meters left of the view in the file "right.vf": rpict `vwright -.06 < right.vf` scene.oct > right.hdr & To move the rad(1) view named "left" 2.5 inches to the right and render from there: rad -v "right `rad -n -s -V -v left examp.rif | vwright 2.5`" examp.rif & To pass a view to rcalc for conversion to some other view: rcalc -n -e `vwright orig < orig.vf` -f viewmod.cal -o view.fmt > new.vf AUTHOR
Greg Ward SEE ALSO
pdfblur(1), rad(1), rcalc(1), rpict(1), rvu(1) RADIANCE
8/29/96 VWRIGHT(1)
All times are GMT -4. The time now is 05:55 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy