World-renowned UC Berkeley astronomer Geoff Marcy groped, kissed and massaged a number of his female graduate students for almost a decade. On the day that the Rosetta Mission landed a probe on a moving comet, project scientist Matt Taylor appeared on international media wearing a shirt printed with pinup girls. In an address to the World Conference of Science Journalists, Nobel laureate Tim Hunt said, “Let me tell you about my trouble with girls … three things happen when they are in the lab. … You fall in love with them, they fall in love with you and when you criticize them, they cry.” He added that he was in favor of single-sex labs because he didn’t want to “stand in the way of women.”

All of these incidents happened within the last year, not centuries ago. Discrimination and harassment of women in science still occurs at unacceptable levels, and those who speak out about sexual harassment are subjected to torrents of online abuse, including rape and death threats. It’s one of the reasons women don’t enter the field — or are fleeing it.

In the United States, women earn about half of doctorates in science and engineering, yet they comprise only 21 percent of full science professors, 5 percent of full engineering professors and 28 percent of the overall workforce. According to studies published by the National Academy of Sciences and the Rand Corporation, female resumes are viewed more negatively, male scientists train fewer female students, and female scientists acquire 37 percent less grant funding.

Equally troubling is the response within the scientific community: denial or silence.

This is borne out of data: a recent study in the Proceedings of the National Academy of Sciences showed that men, particularly male faculty in science, technology, engineering and mathematics, were less likely to believe even quantitative scientific data that gender bias exists in the STEM fields.

Last year, I sent a letter to the American Association for the Advancement of Science and expressed my outrage about a Science cover depicting headless, sexualized transgender women. I also asked for a review, a climate survey and a stricter policy that labs could adopt for best practices.

The editors apologized for the cover, but in June the magazine published a career advice column by Dr. Alice S. Huang telling a female postdoc whose adviser keeps looking down her shirt that she should “put up with it, with good humor if (she) can.” Clearly, despite other admirable diversity efforts from the association, there is a problem. That’s why I sent another letter to the association last week asking them to become leaders in the fight against discrimination in the sciences.

At the beginning of the 21st century, while we are exploring the solar system, unlocking the human genome and creating ever more advanced technology, the demographics and attitudes of scientists and engineers must not be trapped in the 19th century. Women and minorities in science should be able to concentrate on discovery, not on avoiding harassment and defending their very existence in their fields.

Jackie Speier represents San Mateo County and a portion of San Francisco in the U.S. House of Representatives.