home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #1 / NN_1993_1.iso / spool / bit / listserv / sasl / 5525 < prev    next >
Encoding:
Text File  |  1993-01-06  |  4.5 KB  |  98 lines

  1. Comments: Gated by NETNEWS@AUVM.AMERICAN.EDU
  2. Path: sparky!uunet!usc!wupost!darwin.sura.net!paladin.american.edu!auvm!NIHCU.BITNET!HIS
  3. Message-ID: <SAS-L%93010608230384@UGA.CC.UGA.EDU>
  4. Newsgroups: bit.listserv.sas-l
  5. Date:         Wed, 6 Jan 1993 08:20:45 EST
  6. Reply-To:     Howard Schreier <HIS@NIHCU.BITNET>
  7. Sender:       "SAS(r) Discussion" <SAS-L@UGA.BITNET>
  8. From:         Howard Schreier <HIS@NIHCU.BITNET>
  9. Subject: Re: Reading Tricky Flat File
  10. Lines: 86
  11.  
  12. CONTENT:  Response/Comment
  13. SUMMARY:  PROC TRANSPOSE operates on embedded variable names
  14.  
  15. > From:         David Nasser <NASSER@UMSLVMA.BITNET>
  16. >
  17. > The file in question is:
  18. >    "Thrift Financial Report Quarterly, June 1992"
  19. > supplied on tape from:
  20. >    US Office of Thrift Supervision, Wash., DC
  21. >    National Technical Info Service
  22. >    US Dept. of Commerce
  23.  
  24. The NTIS,  part  of  the  Commerce  Department,  acts  as  a
  25. clearinghouse or distribution agency for a great many files,
  26. reports,  etc.   produced  by  and  for   numerous   Federal
  27. agencies.    Responsibility   for   accuracy   of   content,
  28. appropriateness  of  file   structure,   and   adequacy   of
  29. documentation   rests   primarily   with   the   originating
  30. organization (in this case, OTS).
  31.  
  32. > The doc. for this file is very, *very* sparse: there is no record
  33. > layout as such (that we could find).  The data in this file represents
  34. > financial info (i.e. assets, net income, etc.) on Savings and Loan
  35. > Associations (SNLs) reported to one or more federal agencies.
  36. >
  37. > The record length is 128 bytes. All data is character. There are >=180
  38. > records per SNL. The first 79 b.  of selected records for the first
  39. > SNL follow:
  40. >
  41. >G0B192060034904SALEM CO-OP BK                       3 SOUTH BROADWAY
  42. >G0C1920600349030790000ROCKINGHAM                  07416033015
  43. >G0D192060034933010054110803N NNNNNPAAAAAAAAA     00  PPPPPPPPPPPPPXPPPNPP920731
  44. >G0I1920600349SC10   +0000073064SC110  +0000000781SC120  +0000006202SC132  +0000
  45. >G0I1920600349SC150  +0000000000SC162  +0000027884SC166  +0000000000SC170  +0000
  46. >G0I1920600349SC190  +0000000466SC198  +0000000000SC20   +0000000000SC210  +0000
  47. >G0I1920600349SC220  +0000000000SC223  +0000000000SC226  +0000000000SC23   +0000
  48. >G0I1920600349SC24   +0000001251SC240  +0000000600SC250  +0000062805SC253  +0000
  49. >    (172 similar "G0I" records omitted here)                              +0000
  50. >20S1920600349CSS020348053S.C.B., INC.                         3 SOUTH BROADWAY
  51. >20S2920600349CSS020348053SALEM                       NH000003079
  52. >20S3920600349CSS020348053020187470SALEM CO-OPERATIVE BANK              10001A24
  53. >20S4920600349CSS020348053120+0000000102130+0000000000140+0000000102150+00000000
  54. >
  55. > The first 3 recs (starting with "GOB", "G0C", "G0D" resp.) contain
  56. > data for identifiers (i.e. name, address, etc.) and are not a problem.
  57. > The following 177 "G0I" recs have:
  58. >    ID info in the first 13 bytes
  59. >    Six repetitions of:
  60. >      A  7 b. field with a variable name
  61. >      A  1 b. field with a sign associated with:
  62. >      A 10 b. field with a data value
  63. >    7 bytes of apparent garbage at the end of the record
  64. >
  65. > They Have Embedded The Variable NAMES In (nearly) Every Record (some-
  66. > thing I have never _ever_ seen before)!
  67.  
  68. You can always jump  over  the  name  fields  by  using  "+"
  69. pointer controls.
  70.  
  71. > For instance, var name SC10 (Cash less valuation allowance) can be
  72. > read from bytes 14-20 of the first G0I rec. Similarly, the positive
  73. > sign and the actual data value (+0000073064) can be read from bytes
  74. > 21-31. SC10=73064. Piece of cake, eh? eh? There are 6(177)=1062 of
  75. > these beauties.
  76.  
  77. Do you want all 1062?  Perhaps so, at  least  initially.   I
  78. think PROC TRANSPOSE is the answer, since the embedded names
  79. seem to be SAS-legal.
  80.  
  81. > [lines deleted]
  82. > Does it make sense to try to read / support this data with SAS,
  83. > given that we dont necessarily have 40 daze/40 nites to hand-code
  84. > everything (which  will probably change with the next qrtrly file)?
  85.  
  86. I don't know of anything I'd rather use than  SAS  for  this
  87. kind  of  problem.   As long as the definitions (SC10 = Cash
  88. less valuation allowance, etc.), which  you  might  want  to
  89. turn  into SAS variable labels, do not change, you should be
  90. in good shape for the next quarter.
  91.  
  92. /\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\
  93. \   Howard Schreier, U.S. Dept. of Commerce, Washington    /
  94. /                     MVS 5.18 & 6.07                      \
  95. \   Voice: (202) 377-4180        BITNET: HIS@NIHCU         /
  96. /   Fax:   (202) 377-4614      INTERNET: HIS@CU.NIH.GOV    \
  97. \/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/\/
  98.