Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -78,9 +78,11 @@ class Application:
|
|
| 78 |
|
| 79 |
# Aggregate into single data frame and display
|
| 80 |
aggregate = pd.concat(frames, axis=0)
|
|
|
|
|
|
|
| 81 |
st.markdown("**Top month flagged by project**")
|
| 82 |
st.dataframe(
|
| 83 |
-
aggregate
|
| 84 |
column_config={
|
| 85 |
"flagged %": st.column_config.NumberColumn(
|
| 86 |
format="%.2f %%"
|
|
@@ -89,7 +91,7 @@ class Application:
|
|
| 89 |
use_container_width=True
|
| 90 |
)
|
| 91 |
|
| 92 |
-
for repo in
|
| 93 |
st.markdown(f"**{repo}**")
|
| 94 |
st.line_chart(
|
| 95 |
data=self.data[self.data["repo"].str.lower() == repo.lower()].sort_values("month"),
|
|
|
|
| 78 |
|
| 79 |
# Aggregate into single data frame and display
|
| 80 |
aggregate = pd.concat(frames, axis=0)
|
| 81 |
+
aggregate = aggregate.sort_values("flagged %", ascending=False).reset_index(drop=True)
|
| 82 |
+
|
| 83 |
st.markdown("**Top month flagged by project**")
|
| 84 |
st.dataframe(
|
| 85 |
+
data=aggregate,
|
| 86 |
column_config={
|
| 87 |
"flagged %": st.column_config.NumberColumn(
|
| 88 |
format="%.2f %%"
|
|
|
|
| 91 |
use_container_width=True
|
| 92 |
)
|
| 93 |
|
| 94 |
+
for repo in aggregate["repo"]:
|
| 95 |
st.markdown(f"**{repo}**")
|
| 96 |
st.line_chart(
|
| 97 |
data=self.data[self.data["repo"].str.lower() == repo.lower()].sort_values("month"),
|