each &.> empty NB. definded in stdlib in J7 (but not J6 I think) (i.0 0)"_ load 'dir' NB. required in J6.02 but loaded automatically in J7
As far as I know there is no J addon/library that handles gzipped files. There are however windows versions of gunzip and as I mentioned before 7z handles gzip too. I suspect you will just be able to use &.> (aka each) to "loop through" your files. If you provide a simple example of the sort of text you're wanting to process I think it will be easier for us to point you in the right direction. E. is likely to be involved though. On Fri, Nov 4, 2011 at 5:48 PM, Skip Cave <[email protected]> wrote: > The LOG file in each folder is actually LOG.gz, which has been compressed > with the open source, patent-free gzip program (http://www.gzip.org). The > file, when expanded, produces a file named LOG with no extension. Once > expanded, the LOG file is just a plain ASCII text file. > > My first issue will be to discover if there is any utility in the J > libraries that will expand this .gz file to is native form on a Windows > machine. > > Ric Sherlock has shown us code that will find the LOG.gz file in each > directory. I will be trying that out later tonight. > ; (<empty'') -.~ (1 dir ,&'/LOG') each dirpath 'jsource' > I will need to figure out what libraries to load in J to get the "empty",, > "each" and "dir" verbs, so I can try this out. > > Once I figure out how to find and open the files, I will need string > searching utilities to extract the text string I need. > > Can this be done in a non-iterating, array style in J, or will I need > control loops to iterate through all the files? > > Skip > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
