Can we create manager and worker node on same machine for docker swarm

I am trying to run manager and worker on same machine but i getting error.

How would this even make sense? Are you running docker in multiple vm’s and want to span a swarm cluser accross the vm’s?

A single host can be either a manager node OR a worker node…