Infile

Infile

Post by Graeme Kirt » Thu, 06 Sep 2001 21:40:37



If I need to ask a question I ask SAS_L coz the helpdesk take all day to get
back to me ;(

Im trying to read in this text.file, there's a header part b4 the information I
need, this info starts line 9.  My parameters change so I need a way of reading
in the first line then the data, irrespective of what they are.

Basically I want this table into SAS, but not by specifying the parameters in
formats, informats etc....

! X   Y   Vp(V)   Ron(ohms mm)  Idss(mA/mm)  Gm(mS/mm)  Imax(mA/mm)  BV1(V)
BV2(V)  Vknee(V)
-9   5  -9.370   9.078         7.2689E+2    790.550    4.9418E+2    0.674
0.762   0.814
 4   0  -9.370   9.053         7.3279E+2    796.050    5.0845E+2    0.660
0.747   0.816
-9   0  -2.000   9.092         7.3841E+2    783.200    4.9415E+2    0.673
0.762   0.831
-5   0  -9.370   9.065         7.2823E+2    788.850    5.0140E+2    0.667
0.754   0.814
-9  -5  -9.420   9.047         9.9779E+9    790.950    5.0980E+9    0.679
0.759   0.814

TIA...GK

____________________________________________________________________________________________________________

Disclaimer

This email may contain privileged/confidential information and/or copyright
material.  It is intended only for the use of the person(s) to whom it is
addressed and any unauthorised use may be unlawful.  If you receive this email
by mistake, please advise the sender immediately by using the reply facility on
your email software and delete the material from your computer.

Opinions, conclusions and other information in this email that do not relate to
the official business of this organisation shall be understood as neither given
nor endorsed by it.

If this message forms part of a quotation, the quotation is an invitation to
treat only.  No contract subsists until Filtronic Plc (or its subsidiary
companies) accepts your order.  Acceptance of your order is made subject to our
standard Terms and Conditions.

Website Address http://www.filtronic.com

 
 
 

Infile

Post by Gerhard Hellrieg » Thu, 06 Sep 2001 23:15:58


I don't understand exactly, what you want to do! You want to skip 8 or 9
lines? Then you want to read a table, without knowing what's the structure
of that table? Do you want to have the numeric values as numeric values in
SAS or is it enough to have it in strings? What is the difference between
the 1st and the other lines then? If you have strings, it does not matter
what's in. If the 1st line is a header, eg the names of the columns, that's
other. Or are there any informations about the following columns? It is not
possible I think, to read in data without knowing something about them!
Also if you have an example. In that example, there are some columns - but
in another, there are more!? Or less? Or characters instead of numeric data?
Reading the lines as text is no problem. Use a char variable which is long
enough and read it:

data test;
  infile "..." truncover lrecl=900;
  if _n_ = 1 then input ///////; /* to skip the header */

  if a=:"xxxxxx" or a=.... /*is it a header record */ then
     input header $300.;
  else input data $900.;
run;

Quote:>If I need to ask a question I ask SAS_L coz the helpdesk take all day to
get
>back to me ;(

>Im trying to read in this text.file, there's a header part b4 the
information I
>need, this info starts line 9.  My parameters change so I need a way of
reading
>in the first line then the data, irrespective of what they are.

>Basically I want this table into SAS, but not by specifying the parameters
in
>formats, informats etc....

>! X   Y   Vp(V)   Ron(ohms mm)  Idss(mA/mm)  Gm(mS/mm)  Imax(mA/mm)  BV1(V)
>BV2(V)  Vknee(V)
>-9   5  -9.370   9.078         7.2689E+2    790.550    4.9418E+2    0.674
>0.762   0.814
> 4   0  -9.370   9.053         7.3279E+2    796.050    5.0845E+2    0.660
>0.747   0.816
>-9   0  -2.000   9.092         7.3841E+2    783.200    4.9415E+2    0.673
>0.762   0.831
>-5   0  -9.370   9.065         7.2823E+2    788.850    5.0140E+2    0.667
>0.754   0.814
>-9  -5  -9.420   9.047         9.9779E+9    790.950    5.0980E+9    0.679
>0.759   0.814

>TIA...GK

>___________________________________________________________________________

_________________________________

- Show quoted text -

Quote:

>Disclaimer

>This email may contain privileged/confidential information and/or copyright
>material.  It is intended only for the use of the person(s) to whom it is
>addressed and any unauthorised use may be unlawful.  If you receive this
email
>by mistake, please advise the sender immediately by using the reply
facility on
>your email software and delete the material from your computer.

>Opinions, conclusions and other information in this email that do not
relate to
>the official business of this organisation shall be understood as neither
given
>nor endorsed by it.

>If this message forms part of a quotation, the quotation is an invitation
to
>treat only.  No contract subsists until Filtronic Plc (or its subsidiary
>companies) accepts your order.  Acceptance of your order is made subject
to our
>standard Terms and Conditions.

>Website Address http://www.filtronic.com


 
 
 

Infile

Post by Laura Dav » Fri, 07 Sep 2001 01:53:16


This will do it.  The ?? makes SAS set invalid values to missing.  Then use the
automatic variable _N_ to delete the unwanted heading lines.

DATA gk;
  INFILE test MISSOVER;










  IF _N_ < 9 THEN DELETE;
RUN;




cc:    (bcc: Laura Davis/AL/Unitedmail)
Subject:  Infile

If I need to ask a question I ask SAS_L coz the helpdesk take all day to get
back to me ;(

Im trying to read in this text.file, there's a header part b4 the information I
need, this info starts line 9.  My parameters change so I need a way of reading
in the first line then the data, irrespective of what they are.

Basically I want this table into SAS, but not by specifying the parameters in
formats, informats etc....

! X   Y   Vp(V)   Ron(ohms mm)  Idss(mA/mm)  Gm(mS/mm)  Imax(mA/mm)  BV1(V)
BV2(V)  Vknee(V)
-9   5  -9.370   9.078         7.2689E+2    790.550    4.9418E+2    0.674
0.762   0.814
 4   0  -9.370   9.053         7.3279E+2    796.050    5.0845E+2    0.660
0.747   0.816
-9   0  -2.000   9.092         7.3841E+2    783.200    4.9415E+2    0.673
0.762   0.831
-5   0  -9.370   9.065         7.2823E+2    788.850    5.0140E+2    0.667
0.754   0.814
-9  -5  -9.420   9.047         9.9779E+9    790.950    5.0980E+9    0.679
0.759   0.814

TIA...GK

____________________________________________________________________________________________________________

Disclaimer

This email may contain privileged/confidential information and/or copyright
material.  It is intended only for the use of the person(s) to whom it is
addressed and any unauthorised use may be unlawful.  If you receive this email
by mistake, please advise the sender immediately by using the reply facility on
your email software and delete the material from your computer.

Opinions, conclusions and other information in this email that do not relate to
the official business of this organisation shall be understood as neither given
nor endorsed by it.

If this message forms part of a quotation, the quotation is an invitation to
treat only.  No contract subsists until Filtronic Plc (or its subsidiary
companies) accepts your order.  Acceptance of your order is made subject to our
standard Terms and Conditions.

Website Address http://www.filtronic.com

 
 
 

1. About makeSymTlb Error - usage: mksymtab architecture infile - Why?

Dear sir:

Please help me or give me some ideas about the below questions, thanks
in advanced. I really have no ideas to do, why it happens the bellow
error?

c:/Tornado/host/x86-win32/bin/makeSymTbl VX_CPU_FAMILY=ppc
vxWorks.temp > SymTbl.c
usage: mksymtab architecture infile
make[3]: *** [symTbl.c] Error 1

I use Tornado over win32, cygwin development environment/ target
processor MPC8240 / vxWork

thank you very much!
ShuLiang

2. Microcomm FaxBack Number

3. fopen() and infile correspondence

4. FS: Amiga Hardware From A2000

5. How to infile a tab-delimited data

6. expert systems....

7. Use of a string in INFILE

8. HELP ! Search translator for CPC-Homepage !

9. Help on INFILE

10. Infile Statement : Immediate response reqd.

11. Excel DDE - Help with INFILE statement

12. WARNING: Record Truncated (Without an INFILE or INPUT?)

13. infile datalines end=endfile