0

I have the following dataframe in pandas:

IdQos          ConnectionID  Unit   Value
QosQ_Pr0:EwB    CN01210467  Double  -2.0
QosQ_Pr0:C2wB   CN01210467  Double  -2.0
QosQ_Pr0:EnB    CN01210467  Double  -2.0
QosQ_Pr0:lossB  CN01210467  Double  -2.0
QosQ_Pr0:utilB  CN01210467  Double  -2.0

QosQ_Pr0:EwF    CN01210467  Double  -2.0
QosQ_Pr0:C2wF   CN01210467  Double  -2.0
QosQ_Pr0:EnF    CN01210467  Double  -2.0
QosQ_Pr0:lossF  CN01210467  Double  -2.0
QosQ_Pr0:utilF  CN01210467  Double  -2.0

I want to list only the rows that contain "Ew". Like the following

QosQ_Pr0:EwB    CN01210467  Double  -2.0
QosQ_Pr0:EwF    CN01210467  Double  -2.0

I am using: data = data[data['IdQos'] == 'QosQ_Pr0:EwB'] but it only prints EwB

Khalil Mebarkia
  • 135
  • 2
  • 8

0 Answers0