Upon the written order of the prosecuting attorney or the attorney general or upon the filing of a petition signed by 6 electors of a county, the county medical examiner or deputy shall conduct an investigation, as provided in section 5, of the circumstances surrounding any death believed to have occurred in the county. Upon determination of the prosecuting attorney or upon the determination of the examiner an inquest shall be held by a district court judge or a municipal court judge.