how to add and delete a string in front of a string by sed?
I am using R program. Part of my program is as following
Code:
pvper[j,6]=PCH(y,x,numper) Code:
pvper[j,6]=PCH(y,x,numper) Code:
sed '/pvper\[j,8\]=/a #' K_10_mmodel_1.R I also tried Code:
sed '/pvper\[j,8\]=/i #' K_10_mmodel_1.R |
is this what you are after:
Code:
[schneidz@hyper ~]$ cat ben.wang |
Quote:
Code:
pvper[j,6]=PCH(y,x,numper) |
I'm confused?? You just asked to put the '#' symbol there ... if you don't want it don't run the sed command.
|
Quote:
|
Quote:
Code:
pvper[j,6]=PCH(y,x,numper) How can I delete #? |
I already know that, just reverse it.
Thanks a lot. |
All times are GMT -5. The time now is 09:23 PM. |