Sponsored Content
Full Discussion: deleting a character
Top Forums Shell Programming and Scripting deleting a character Post 302357732 by phil_heath on Wednesday 30th of September 2009 12:39:55 PM
Old 09-30-2009
deleting a character

Hi I am having problems deleting a character

Basically I want to recognize lines with > and then delete a character that is seperated by a space. Here is an example of how the file looks like.

Code:
>chr86 86


Heres what I want it to look like:

Code:
>chr86

thanks

Phil
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Problem deleting file with special character

I'm having problems deleting a file with a special character and I'm hoping that somebody here can help. The file "-osample1.c" will not remove from my directory. Here is an example of what happens. Any ideas would be appreciated. > ls *sample1* ls: illegal option -- . usage: ls... (2 Replies)
Discussion started by: hart1165
2 Replies

2. Shell Programming and Scripting

deleting newline characters but not the "true" \n character

hi, i have a file that has about 4500 rows. this was an old microsoft access databse and what i am trying to do is take out the old extra \n newline characters but not take out the "true" newline character. I will explain. i was trying to write a regular expression, but that was not... (1 Reply)
Discussion started by: caddyjoe77
1 Replies

3. UNIX for Advanced & Expert Users

Deleting end of line $ character in file

Hi, I've got a file where in the middle of the record is a $ end of line character, visible only when I open the file in vi and do :set list. How to I get rid of the character in the middle and keep it at the end. The middle $ character always appears after SW, so that can be used to tag it.... (3 Replies)
Discussion started by: bwrynz1
3 Replies

4. Shell Programming and Scripting

Deleting a character

Hi I have a file that looks like this: arg1 ert arg_7 ert arg_9 ert ban ert Basically what I want to do is delete the _# ending. So the output will look like this: arg1 ert arg ert arg ert ban ert thanks (5 Replies)
Discussion started by: kylle345
5 Replies

5. Shell Programming and Scripting

Deleting all characters from 350th character to 450th character from the log file

Hi All, I have a big log file i want to delete all characters (between 350th to 450th characters) starting at 350th character position to 450th character position. please advice or sample code. (6 Replies)
Discussion started by: rajeshorpu
6 Replies

6. UNIX for Dummies Questions & Answers

Deleting all instances of a certain character from a text file

In my command prompt I did: sed 's/\://' mytextfile > newtextfile But it only deleted the first instance of : in each line when some lines have multiple : appearing in each one. How can I delete all the : from the entire file? (1 Reply)
Discussion started by: guitarscn
1 Replies

7. Shell Programming and Scripting

Deleting sequences based on character frequency

This is what I would like to accomplish, I have an input file (file A) that consist of thousands of sequence elements with the same number of characters (length), each headed by a free text header starting with the chevron ‘>' character followed by the ID (all different IDs with different lenghts)... (9 Replies)
Discussion started by: Xterra
9 Replies

8. UNIX for Advanced & Expert Users

Deleting lines if ith character is x

Hello, I am trying to remove all lines of a data file if the 32nd character in the line is 0. Is there a short, one-line way to do this with grep, awk, or sed? Thanks! (4 Replies)
Discussion started by: palex
4 Replies

9. Shell Programming and Scripting

Deleting rows starting with a character and word

Hi, I have multiple files of same format and I want to delete the lines starting with # and The from all of them I am using egrep -v '^(#|$)' for # but unable to do for both # and The Please guide Thanks (12 Replies)
Discussion started by: bioinfo
12 Replies

10. UNIX for Dummies Questions & Answers

Deleting a pattern in UNIX without deleting the entire line

Hi I have a file: r58778.3|SOURCES={KEY=f665931a...,fw,221-705}|ERRORS={16_1:T,30_1:T,56_1:C,57_1:T,59_1:A,101_1:A,115:-,158_1:C,186_1:A,204:-,271_1:T,305:-,350_1:C,368_1:G,442_1:C,472_1:G,477_1:A}|SOURCE_1="Contig_1092402550638"(f665931a359e36cea0976db191ff60ff09cc816e) I want to retain... (15 Replies)
Discussion started by: Alyaa
15 Replies
FANN_READ_TRAIN_FROM_FILE(3)						 1					      FANN_READ_TRAIN_FROM_FILE(3)

fann_read_train_from_file - Reads a file that stores training data

SYNOPSIS
resource fann_read_train_from_file (string $filename) DESCRIPTION
Reads a file that stores training data. PARAMETERS
o $filename - The input file in the following format: num_train_data num_input num_output inputdata seperated by space outputdata seperated by space inputdata seperated by space outputdata seperated by space RETURN VALUES
Returns a train data resource on success, or FALSE on error. EXAMPLES
Example #1 fann_read_train_from_file example <?php $train_data = fann_read_train_from_file("xor.data"); if ($train_data) { // Do something with $train_data for XOR function } ?> Contents of xor.data 4 2 1 -1 -1 -1 -1 1 1 1 -1 1 1 1 -1 SEE ALSO
fann_train_on_data(3), fann_destroy_train(3), fann_save_train(3). PHP Documentation Group FANN_READ_TRAIN_FROM_FILE(3)
All times are GMT -4. The time now is 09:13 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy