Re: [Chicken-users] Parsing HTML, best practice with Chicken

2015-01-13 Thread Peter Bex
On Mon, Jan 12, 2015 at 11:49:32AM +0100, m...@freeshell.de wrote: First, to lighten up spirits a bit: at least for me it was easier to start with Chicken than with Clojure. That's good news :) That being said, I think it is hard to compete against Python in terms of documentation, number of

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2015-01-12 Thread mfv
Hello and happy new year to all! Peter, Hm, that's unfortunate. However, I've heard this complaint before. Do you have any tips on how we can improve the situation? First, to lighten up spirits a bit: at least for me it was easier to start with Chicken than with Clojure. That being said, I

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2015-01-12 Thread Evan Hanson
Hi Piotr, I don't have much to add, other than to say that I agree with most of your points and to thank you for taking the time to write up your thoughts. On 2015-01-12 11:49, m...@freeshell.de wrote: -- an instruction how to get a running IDE with a REPL. I really struggled here (Sublime

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-31 Thread John Cowan
mfv scripsit: I am still puzzled how undefined is generated. It can not come from the (if (string? str) ... clause. Or does it? I understand that you used 'and' and remove one redundant check with if. But what form produced the #undefined output? The form (if p t) will return an

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-29 Thread Mario Domenech Goulart
Hi, On Mon, 29 Dec 2014 12:12:22 +0100 Kooda ko...@upyum.com wrote: ;; --- member? returns #t if elemnt x is in list lst. ;; --- ref: ;; --- http://stackoverflow.com/questions/14668616/scheme-fold-map-and-filter-functions ;; --- use: (member? a (list a 1)) -- #t (define (member? x lst)

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-29 Thread Peter Bex
On Mon, Dec 29, 2014 at 03:28:15AM +0100, mfv wrote: So far, I have been getting the site with http-client, the raw html to sxml with html-parser, and trying to process the resulting list with matchable/srfi-13. I would recommend avoiding that, as it can get really messy. sxpath is meant for

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-29 Thread mfv
Hey! Sxml-transform and other sxml related eggs can certainly help you here, but I don’t know them really well so I can’t help you with that. thanks, I will look into that. ;; saving function (define (savedata somedata filename) (call-with-output-file filename (lambda (p)

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-29 Thread Ivan Raikov
Hello Piotr, The neuromorpho egg is a scraper-like utility to fetch information from a public database with neuronal reconstructions. You can look at the code for examples of page scraping with sxpath. In particular, take a look at the procedures table-alist, extract-metadata,

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-29 Thread mfv
Hello, I somehow always manage to get it working with sxpath when I need to do some web scraping, but it's somewhat painful. Thanks, I will have a look at sxpath. Are there any packages like Python's Beautifulsoup in the Chicken arsenal? That sort of thing is sorely lacking.

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-29 Thread Peter Bex
On Mon, Dec 29, 2014 at 07:47:33PM +0100, mfv wrote: All in all, I must say that it is much more difficult to get going with Chicken then with Python. The overall language is simple, but the learning curve is fairly steep - and I am not sure whether it will pay off. Hm, that's unfortunate.

Re: [Chicken-users] Parsing HTML, best practice with Chicken

2014-12-29 Thread Alex Shinn
On Tue, Dec 30, 2014 at 3:47 AM, mfv m...@freeshell.de wrote: Hello, I somehow always manage to get it working with sxpath when I need to do some web scraping, but it's somewhat painful. Thanks, I will have a look at sxpath. Are there any packages like Python's Beautifulsoup in the

[Chicken-users] Parsing HTML, best practice with Chicken

2014-12-28 Thread mfv
Hello, I am currently playing around the Chicken and the web. More precisely, I want to make some web link collection and see how well it goes for me when scraping web sites for links and content. Which eggs would you recommend for that? What should I avoid doing? So far, I have been getting