close issue #21 - more pig work