Multichem commited on
Commit
be550d2
·
verified ·
1 Parent(s): 0138b4e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -78,14 +78,14 @@ def convert_df(array):
78
 
79
  @st.cache_data
80
  def calculate_DK_value_frequencies(np_array):
81
- unique, counts = np.unique(np_array[2:10], return_counts=True)
82
  frequencies = counts / len(np_array) # Normalize by the number of rows
83
  combined_array = np.column_stack((unique, frequencies))
84
  return combined_array
85
 
86
  @st.cache_data
87
  def calculate_FD_value_frequencies(np_array):
88
- unique, counts = np.unique(np_array[1:9], return_counts=True)
89
  frequencies = counts / len(np_array) # Normalize by the number of rows
90
  combined_array = np.column_stack((unique, frequencies))
91
  return combined_array
 
78
 
79
  @st.cache_data
80
  def calculate_DK_value_frequencies(np_array):
81
+ unique, counts = np.unique(np_array[:, :9], return_counts=True)
82
  frequencies = counts / len(np_array) # Normalize by the number of rows
83
  combined_array = np.column_stack((unique, frequencies))
84
  return combined_array
85
 
86
  @st.cache_data
87
  def calculate_FD_value_frequencies(np_array):
88
+ unique, counts = np.unique(np_array[:, :8], return_counts=True)
89
  frequencies = counts / len(np_array) # Normalize by the number of rows
90
  combined_array = np.column_stack((unique, frequencies))
91
  return combined_array