This approach reminded me quite a bit of what Mojo::DOM and Mojo::DOM:CSS modules give you, and the ojo command line tool for perl (called as perl -Mojo).
Here's section 5 from that article rewritten:
perl -MList::MoreUtils=zip -Mojo -E 'say g("http://en.wikipedia.org/wiki/List_of_countries_and_territori... > tr:not(:first-child)")->pluck(sub{ j { country=>$_->find("td")->[1]->text, border=>$_->find("td")->[2]->text, surface=>$_->find("td")->[3]->text, ratio=>$_->find("td")->[4]->text } })' | head
{"ratio":"7.2727273","surface":"0.44","country":"Vatican City","border":"3.2"}
{"ratio":"2.2000000","surface":"2","country":"Monaco","border":"4.4"}
{"ratio":"0.6393443","surface":"61","country":"San Marino","border":"39"}
{"ratio":"0.4750000","surface":"160","country":"Liechtenstein","border":"76"}
{"ratio":"0.3000000","surface":"34","country":"Sint Maarten (Netherlands)","border":"10.2"}
{"ratio":"0.2570513","surface":"468","country":"Andorra","border":"120.3"}
{"ratio":"0.2000000","surface":"6","country":"Gibraltar (United Kingdom)","border":"1.2"}
{"ratio":"0.1888889","surface":"54","country":"Saint Martin (France)","border":"10.2"}
{"ratio":"0.1388244","surface":"2586","country":"Luxembourg","border":"359"}
{"ratio":"0.0749196","surface":"6220","country":"Palestinian territories","border":"466"}
And here's the original command:curl -s 'http://en.wikipedia.org/wiki/List_of_countries_and_territori... | scrape -be 'table.wikitable > tr:not(:first-child)' | xml2json | jq -c '.html.body.tr[] | {country: .td[1][], border: .td[2][], surface: .td[3][], ratio: .td[4][]}' | head
Fairly comparable, but there's a whole world of Perl modules for me to pull in and use with the first one.