What would this do? if the file that has the proper column/row structure is called "original.1D" and the one-column file that has the proper integers is called "onecolumn.1D" then how would this code be written? which input is "file"?
Thanks
---------- Post updated at 02:34 PM ---------- Previous update was at 02:20 PM ----------
What's MATLAB? What does it have to do with shell scripting?
[/QUOTE]
What I meant is that I know in the programming language Matlab when it reads a text file it reads it one word at a time and the word that its on can be used as a variable and has an assigned name. Then theres another command that goes to the next word of the file so that it can go through each word in a file, do something with it, and move onto the next word. Thats what I want to do.
I want to go through the onecolumn file integer by integer (while at the same time going through the other file integer by integer) and switch the onecolumn integer into the integer of the multicolumn file one word at a time.
Hi All,
I have a table with 10 columns. Some columns(2nd,4th,5th,7th,8th and 10th) are Not Null columns. I'll get a tab-delimited file and want to check col by col and generate seperate error code for each col eg:102 if 2nd col value is NULL and 104 if 4th col value is NULL so on... I am a... (7 Replies)
I have a program which gives me the output as a single column with hundreds of rows like:
213
314
324
324
123
I want to be able to create a new file from this file which allows me to set the number of rows and columns in the new file, i.e. for this example, if I specify 3 rows and 2... (5 Replies)
Hi,
I have a small requirement in chainging the rows to columns. The below example.txt contains info as shown
Name:Person1
Age:30
Name:Person2
Age:40
Name:Person3
Age:50
I want to make it displayed as hown below
Name:Person1 Age:30
Name:person2 Age:40
Name:Person3 Age:50
I... (4 Replies)
Hi, Iam new to unix. I have one input file .
Input file :
ID1~Name1~Place1
ID2~Name2~Place2
ID3~Name3~Place3
I need output such that only first column should change to fixed width column of 15 characters of length.
Output File:
ID1<<12 spaces>>Name1~Place1
ID2<<12... (5 Replies)
i have a file a.txt contents as 1,2,3,4,......etc...in a single line, i want to write to another file in rows as
1
2
3
4
5
can u help?
i do not know the length of a.txt (4 Replies)
I have 2 files,
file01= 7 columns, row unknown (but few)
file02= 7 columns, row unknown (but many)
now I want to create an output with the first field that is shared in both of them and then subtract the results from the rest of the fields and print there
e.g.
file 01
James|0|50|25|10|50|30... (1 Reply)
Hi Friends,
I have come across some files where some of the columns don not have data.
Key, Data1,Data2,Data3,Data4,Data5
A,5,6,,10,,
A,3,4,,3,,
B,1,,4,5,,
B,2,,3,4,,
If we see the above data on Data5 column do not have any row got filled. So remove only that column(Here Data5) and... (4 Replies)
HI,
My Input file data is
dn:adcfgeneral
id:13343
Name:xxxxxx
Password:iutyerwuitywue wpuwt
tuiytruityrutyrwtyrwp
dn:cdferwjyyyy
id:3875
Name:yyyy
Password :hgfdsjkfhdsfkdlshf
dshfkldshfdklsfh
interset:uiuiufj
My output should be
... (6 Replies)
Discussion started by: dineshaila
6 Replies
LEARN ABOUT SUNOS
factor
factor(1) User Commands factor(1)NAME
factor - obtain the prime factors of a number
SYNOPSIS
factor [integer]
DESCRIPTION
factor writes to standard input all prime factors for any positive integer less than or equal to 10**14. The prime factors are written the
proper number of times.
If factor is used without an argument, it waits for an integer to be entered. After entry of the integer, it factors it, writes its prime
factors the proper number of times, and then waits for another integer. factor exits if a 0 or any non-numeric character is entered.
If factor is invoked with an argument (integer), it writes the integer, factors it and writes all the prime factors as described above, and
then exits. If the argument is 0 or non-numeric, factor writes a 0 and then exits.
The maximum time to factor an integer is proportional to sqrt(n), where n is the integer which is entered. factor will take this time when
n is prime or the square of a prime.
OPERANDS
integer Any positive integer less than or equal to 10**14.
EXIT STATUS
0 Successful completion.
1 An error occurred.
DIAGNOSTICS
factor prints the error message Ouch! for input out of range or for garbage input.
ATTRIBUTES
See attributes(5) for descriptions of the following attributes:
+-----------------------------+-----------------------------+
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
+-----------------------------+-----------------------------+
|Availability |SUNWesu |
+-----------------------------+-----------------------------+
SEE ALSO attributes(5)SunOS 5.10 31 Jan 1996 factor(1)