<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def download(ctx):
 """Download data."""

    log.debug('chemdataextractor.data.download')
    count = 0
    for package in PACKAGES:
        success = package.download()
        if success:
            count += 1
    click.echo('Successfully downloaded %s new data packages (%s existing)' % (count, len(PACKAGES) - count))