Heath Street is currently the last stop on the Green Line "E" Branch. Though, at one point, the electric trolley ran all the way to the Arborway stop (near the Forest Hills Station in Jamaica Plain). The trolley was an important means of transportation for residents of JP; allowing them access to hospitals, universities, and downtown Boston.
Because of societal changes like improved roads, reliance on cars, efficiency of buses, and subways; the electric trolley became less important. In 1985, the MBTA suspended trolley service from -- Heath Street to Arborway-- for maintenance reasons, and replaced it with the 39 bus. The suspension became permanent after much controversy (and a lawsuit) from JP community groups, and in 2008, the track vestiges were paved over. The 39 bus goes from Forest Hills to Back Bay, and runs parallel to the "E" Branch from Heath Street; raising questions about the future of the "E" Branch.
If you want to see what Centre Street in JP looked like with a trolley, check out this 1967 photo.