minimum viable version of improved stats
This commit is contained in:
@@ -968,6 +968,12 @@ def read_cols_df_sql(ids,columns):
|
||||
connection = engine.raw_connection()
|
||||
df = pd.read_sql_query(query,engine)
|
||||
df = df.fillna(value=0)
|
||||
try:
|
||||
df['peakforce'] = df['peakforce']*lbstoN
|
||||
df['averageforce'] = df['averageforce']*lbstoN
|
||||
except KeyError:
|
||||
pass
|
||||
|
||||
engine.dispose()
|
||||
return df
|
||||
|
||||
@@ -980,6 +986,12 @@ def read_df_sql(id):
|
||||
|
||||
engine.dispose()
|
||||
df = df.fillna(value=0)
|
||||
try:
|
||||
df['peakforce'] = df['peakforce']*lbstoN
|
||||
df['averageforce'] = df['averageforce']*lbstoN
|
||||
except KeyError:
|
||||
pass
|
||||
|
||||
return df
|
||||
|
||||
# Get the necessary data from the strokedata table in the DB.
|
||||
|
||||
Reference in New Issue
Block a user