Click here to Skip to main content
15,886,822 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I have a Pandas Dataframe which looks like below


test_case,test_type,source_path,table_path,test_status,record_count,table_partition,load_ts,id
check1,T1,/documents/Status,pass,nan,nan,2021-02-13 19:06:02.527,1
check2,T1,/documents/Status,fail,nan,nan,2021-02-11 19:06:02.527,2
check3,T2,/documents/Status,pass,nan,nan,2021-02-12 19:06:02.527,3
check4,T2,/documents/Status,fail,nan,nan,2021-02-12 19:06:02.527,4


I want my Output or Visualization Plots which tell: For each date(load_ts column),show test case names(test_case column values) which have passed and test case names which have failed


The problem with the below code is that it only shows test status count of pass and fail per date but i want to further drill down and see that which test cases are under pass and which are under fail. Kindly see the below plot which i have created as of now.


What I have tried:

import pandas as pd
import matplotlib.pyplot as plt
import numpy as np
import seaborn as sns
plt.figure(figsize=(15,16))
sns.countplot(x='load_ts', hue="test_status", data=result_df)

plt.show()
Posted

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900