So you only want a legend to be shown if there are subplots and the pass `legend` parameter is `True`? What if `subplots` is `False`? Then the `legend` keyword argument would have no effect.