Every person arrested or accused of a crime has the right to legal representation. In order to decide which cases to drop and which cases to prosecute, the police and related legal counsel must take many factors into account. For example, sometimes the victim of a crime will decide to drop their charges; this will affect the decision to prosecute since the crime might be entirely against that one person. If, however, a victim drops their charges while there are other charges pending, the case might still be prosecuted. Many of these decisions are made on-the-fly by legal counsel based on experience and on the random and unique factors of the case.
The police do not have the explicit power to drop a case; they may stop investigation, but the legal aspect is usually out of their hands. Once a person is arrested, their legal counsel and the prosecution office become responsible for their eventual case, either in court or under mediation. There are innumerable rules and regulations regarding these decisions.
Of course, a defendant with a past history of criminal activity is more likely to be tried even if parts of the case are dropped; a person with a cleaner background may be allowed bail, but the case might still go forward. In either case, the decision is made by the prosecution, not by the police or legal counsel. Essentially, the police fulfil their obligation by arresting and then investigating to the best of their ability; most further decisions regarding the case are made by the D.A.'s office, barring extraordinary circumstances.
The decision about whether to prosecute a case is made largely on the basis of the seriousness of the crime and the likelihood of winning the case.
Prosecutors evaluate each case to determine whether to prosecute. They look at how serious the case is. This involves looking at the nature of the crime. It also involves looking at the background of the suspect. A suspect with more of a criminal record or more perceived moral culpability is more likely to be prosecuted.
Prosecutors also look at the evidence that they have. They look to see if they have enough evidence that they are likely to force a plea bargain or to win at trial. This combination of the seriousness of the case and the likelihood of winning is the main basis for deciding whether to prosecute a case.