I figured it out.
My code keys in on the unique identifier of owner (automatically assigned by Wix). As the Admin, all of the sample data I’ve put in the collection is under that owner. Thus in preview mode I see them all and the functions work.
When I go to the published side of things my owner ID changes (no longer the same as the Admin). When I queried the collection there was no data for me to read because none of the records existed for the different owner I was assigned. To solve everything, I created a new entry into the collection via a form on the public site and now it all works.