Personally no I wouldn't. I went to a childs funeral (13 yr) last year and I took my son as they were friends. My other 2 boys decided on the day they didn't want to go. At 4 they may have a minor understanding of death but they don't understand the funeral process fully and it may upset them to see a lot of people upset or like you said want to play as kids do that

Maybe do something special with your son like plant a tree or release a balloon with a letter in it.. Just on your own as your own little thing for him...

So sorry for your friends loss..