When it comes down to it, the clothing we choose to wear is an indication of what our intentions and purpose are.
Wearing overalls and big rubber boots? You’re probably going to muck out a stable.
Wearing a flowery summer dress? The weather is warm, the company is casual, and you want to look feminine.
Wearing a bathing suit and shorts? You’re probably on your way to a water park or the beach, either way, you’re taking part in a leisure activity.
Clothes reflect the social significance of the activity. We used to differentiate to a high degree between public and private activities. We used to reserve certain clothes for certain functions, both extremely formal and extremely informal. We used to be able to tell, with a glance at a person’s clothing, what their gender, occupation, financial status, and possibly religion were.
Our society and culture has shifted so that there are far fewer designations between casual and formal, and occasions that used to require a very specific type of clothing (tennis, anyone?) is now much more generic. There’s a certain appeal to changing our expectations of clothing to something much more relaxed and anonymous. Generally, you can’t tell if someone’s on their way to the courthouse or the movies anymore.
But there are still times when a person’s dress reflects their recognition of the solemnity of an occasion. Job interviews for most non-manual positions require that the applicant show they recognize it as a formal occasion. Appearing before a judge on legal matters is another time when more formal dress is appropriate. And a funeral - where you aren’t just recognizing the worth of the decedent’s life, but mourning their loss and comforting their loved ones - is one of the most formal occasions of our social milieu. The only ones that are on par are weddings, some graduations, and being sworn into public office.
Certainly weddings and graduations have a great deal more latitude, as they are usually planned well in advance and the tastes of the participants rule. But there is very rarely any warning that a death is imminent, and the funeral almost always follows within a week’s time. With that little window, it is best to consider the accepted, traditional rules as a default and be guided by them unless they are overruled by specific requests directly from the decedent and those who mourn him or her.
I can’t think of a single situation where a person was resented for dressing more formally than expected, but this thread is an excellent example of the hurt feelings and outraged sensibilities over dress that is less formal than expected. And if a person shows up in a work shirt and pants, but it is their best clothing? Then they are dressed as formally as they can be, and there is nothing to take offense over.