It depends on how you are saying it.
If you are interrupting them mid-sentence and saying something in a very brusk, rude tone, then yeah, of course it's going to come across as rude. If you just cut them off with "please don't speak to me", and then just ignore them, the fact that you said "please" doesn't offset the rest of the statement, and the feeling behind it.
Now, if you are at least being polite enough to wait until they stop speaking, and say something like "Sir/maam, I'm sorry but I just really don't feel like talking right now, and would like to be left alone, thank you" or "I'm sorry but I just don't care to discuss that topic right now, and would like to be alone, thank you." Or something along that line, then no, I wouldn't say that you were being rude. They still might get offended, as people are touchy that way, but I would say that in those cases you did your best to be polite about it.
The method you stated above, of just directly saying "please don't talk to me", is indeed, a very effective way to stop a conversation, but it doesn't sound very polite, at least not the way you stated it.
I'm not voting because your question as presented in the poll, is very different from what you are asking in the subject line, and the body of your thread. Simply saying "is it rude to tell someone you don't want to talk" is too vague, it all depends on context and presentation.
If you are interrupting them mid-sentence and saying something in a very brusk, rude tone, then yeah, of course it's going to come across as rude. If you just cut them off with "please don't speak to me", and then just ignore them, the fact that you said "please" doesn't offset the rest of the statement, and the feeling behind it.
Now, if you are at least being polite enough to wait until they stop speaking, and say something like "Sir/maam, I'm sorry but I just really don't feel like talking right now, and would like to be left alone, thank you" or "I'm sorry but I just don't care to discuss that topic right now, and would like to be alone, thank you." Or something along that line, then no, I wouldn't say that you were being rude. They still might get offended, as people are touchy that way, but I would say that in those cases you did your best to be polite about it.
The method you stated above, of just directly saying "please don't talk to me", is indeed, a very effective way to stop a conversation, but it doesn't sound very polite, at least not the way you stated it.
I'm not voting because your question as presented in the poll, is very different from what you are asking in the subject line, and the body of your thread. Simply saying "is it rude to tell someone you don't want to talk" is too vague, it all depends on context and presentation.