tave-st commited on
Commit
7d2b157
1 Parent(s): 29cc895

remove leadining decimals

Browse files
Files changed (2) hide show
  1. pages/clustering.py +2 -1
  2. recommender_system.py +2 -1
pages/clustering.py CHANGED
@@ -9,6 +9,7 @@ import plotly.express as px
9
  import itertools
10
  from typing import Dict, List
11
 
 
12
  SIDEBAR_DESCRIPTION = """
13
  # Client clustering
14
 
@@ -319,7 +320,7 @@ def main():
319
  "\nThis is the processed dataset with information about the clients, such as"
320
  " the RFM values and the clusters they belong to."
321
  )
322
- st.dataframe(df_rfm)
323
 
324
  cluster_info_dict = defaultdict(list)
325
 
 
9
  import itertools
10
  from typing import Dict, List
11
 
12
+
13
  SIDEBAR_DESCRIPTION = """
14
  # Client clustering
15
 
 
320
  "\nThis is the processed dataset with information about the clients, such as"
321
  " the RFM values and the clusters they belong to."
322
  )
323
+ st.dataframe(df_rfm.style.format(formatter={"Revenue": "{:.2f}"}))
324
 
325
  cluster_info_dict = defaultdict(list)
326
 
recommender_system.py CHANGED
@@ -11,7 +11,7 @@ import time
11
  from utils import load_and_preprocess_data
12
 
13
  import matplotlib.pyplot as plt
14
- from typing import Union, List, Dict, Any, TYPE_CHECKING
15
  import plotly.graph_objects as go
16
 
17
 
@@ -323,6 +323,7 @@ The dataset used for these computations is the following:
323
  )
324
  st.sidebar.markdown(SIDEBAR_DESCRIPTION)
325
 
 
326
  # Show the data
327
  st.dataframe(
328
  data.drop(
 
11
  from utils import load_and_preprocess_data
12
 
13
  import matplotlib.pyplot as plt
14
+ from typing import Union, List, Dict, Any
15
  import plotly.graph_objects as go
16
 
17
 
 
323
  )
324
  st.sidebar.markdown(SIDEBAR_DESCRIPTION)
325
 
326
+
327
  # Show the data
328
  st.dataframe(
329
  data.drop(