Image copyright Getty Images Image caption The new law aims to protect medical workers from violent incidents

China has introduced a new law with the aim of preventing violence against medical workers.

The announcement comes days after a female doctor was stabbed to death at a Beijing hospital.

The law bans any organisation or individual from threatening or harming the personal safety or dignity of medical workers, according to state media.

It will take effect on 1 June next year.

Yang Wen was working at Beijing Civil Aviation General Hospital's emergency ward on 24 December when she was attacked by a man.

Chinese media claims he was related to a patient who was receiving treatment on the ward.

Zhao Ning, an official at the National Health Commission said: "We are deeply aggrieved and enraged by this incident, particularly as the relevant law was being deliberated."

Under the new law, those "disturbing the medical environment, or harming medical workers' safety and dignity" will be given administrative punishments such as detention or a fine. It will also punish people found illegally obtaining, using or disclosing people's private healthcare information.

It's not the first case of a death or violence in a Chinese hospital.

According to CGTN, there were at least 12 "medical incidents" involving violence and two medical workers were killed in 2018 alone.

A recent survey by Dingxiang Yuan, an online site for healthcare professionals, found 85% of doctors had experienced violence in their workplace.

The article went on to add: "Doctors are responsible for protecting society from diseases. Who protects doctors?"

An article in medical journal The Lancet claims there are many reasons why doctors in Chinese hospitals are under threat.

Poor funding can result in errors or breakdowns in communication between doctors and patients, while other factors include negative media reports about medical staff, unrealistic expectations and large healthcare bills for families on low incomes.

Media playback is unsupported on your device Media caption John Sudworth looks at the rise in attacks at Chinese hospitals

In October, a female doctor was fatally stabbed by a cancer patient at a hospital in Lanzhou.

In August 2018, a doctor at a Tianjin hospital was stabbed to death by three men.

A few months before, a doctor in Anhui province was stabbed to death following an argument with the husband of a patient.

Some hospitals have even resorted to teaching its medical staff self defence.