If you want to hide element entirely, simply go to recommendation slot settings and click Disable recommendation slot which will hide the recommendation from the public, but will keep the placeholder still in place on the page so that you can easily enable it at any time directly from the Nosto admin without the need to adjust or edit your site’s design code or templates.
If you want to add a condition for an element from displaying itself, it’s easiest to edit min amount setting for a recommendation slot
For example if an element should be hided if the algorithm doesn’t return enough results i.e. products, set the value in min amount settings to four.