I have a pyspark sc initialized.
task1 = (text.filter(lambda x: len(x)>0 )) # to filter empty lines
task1.collect()
My goal is to filter out lines starting with 'URL' in this text snippet:
['URL: http://www.nytimes.com/2016/06/30/sports/baseball/washington-nationals-max-scherzer-baffles-mets-completing-a-sweep.html', 'WASHINGTON — Stellar pitching kept the Mets afloat in the first half of last season despite their offensive woes.
How can I do this in pyspark syntax easily?