Analyses (.ana)#
Contains functions to analyse isometric tests, Wingate tests, Sprint tests, and Submax tests on the wheelchair ergometer.
- worklab.ana.ana_sprint(data, data_pbp, half=5, title=None)[source]#
Sprint test analyse. Plot a figure with the power, speed and distance for left and right separate. Also saves important outcomes
- Parameters:
data (dict) – processed and cut ergometer data dictionary with dataframes
data_pbp (dict) – processed and cut push_by_push ergometer data dictionary with dataframes
half (float, optional) – half-time of the sprint, default is 5 s
title (str, optional) – title of figure
- Returns:
fig (matplotlib.figure.Figure)
outcomes (dataframe)
- worklab.ana.ana_submax(data_ergo, data_pbp, data_spiro=None)[source]#
Sub maximal test analyse. Saves important outcomes
- Parameters:
data_ergo (pd.DataFrame) – processed and cut ergometer data
data_pbp (pd.DataFrame) – processed and cut ergometer data
data_spiro (pd.DataFrame) – processed and cut spirometer data
- Returns:
outcomes
- Return type:
pd.DataFrame
- worklab.ana.cut_data(data, start, end, distance=True)[source]#
Cuts data to time of interest
- Parameters:
data (dict) – processed ergometer data dictionary with dataframes
start (float) – start time [s]
end (float) – end time [s]
distance (bool, optional) – resets distance to 0 at start, default is True.
- Returns:
data – data cut to time of interest
- Return type:
dict
- worklab.ana.force_vel_profiling(filename, athlete='PP01', classification='LP', sport='WR', duration=10, var='mean', push_cutoff=1, minpeak=None, unit='ms', n_sprints=7, res_names=None, x_lim=6, y_lim=None)[source]#
Force velocity profiling (individualised) on the LODE wheelchair ergometer.
- Parameters:
filename (str) – main path name which contain all athlete data, with all sprints as separate Excel files within each athlete folder (e.g., 0, 1, 2, 3, 4, 5, 6)
athlete (str, default 'PP01') – The alphanumeric identifier or acronym assigned to the participant (e.g., ‘AS’, ‘PP01’). Determines the target data folder name.
classification (str, default 'LP') – The sport-specific physical impairment classification tier. Accepts ‘HP’ (High Point) or ‘LP’ (Low Point)
sport (str, default 'WR') – The sport, e.g., WR = Wheelchair Rugby
duration (int, default 10) – The length of sprints in seconds
var (str) – ‘mean’ force and velocity, ‘peak’ force and velocity, or ‘impulse’ and velocity
push_cutoff (int) – numbers of pushes to cut off at the start, default is 1
minpeak (int) – Minimum peak detection on the torque signal default is None, which will automatically detect peaks based on mean
unit (str) – unit of measured ‘speed’ column; ms, kmh or mph, default is ms
n_sprints (int) – Total number of sprints, default is 7
res_names – list of sprint names, default [‘Low’, ‘Standard’, ‘25%’, ‘50%’, ‘75%’, ‘100%’, ‘125%’]
x_lim (int) – x limit axis, default is 6
y_lim (int) – y limit axis, default is 800
- Returns:
var_fvc (pd.DataFrame()) – Containing the force-velocity outcomes (R2, optimal vel/power, coordinates)
outcomes_mean_all (pd.DataFrame()) – Mean outcome variables of the sprints (mean, right, left)
data_pbp_all (pd.DataFrame()) – Push-by-push outcomes for all sprints (mean, right, left)
- worklab.ana.isometricforce(data, title=None, height=40, distance=500, ylim=None)[source]#
Calculates the three seconds maximal user force and plots it against time (darkblue). Peaks are annotated with a dot and with the height of the peak, max value is shown in the corner. Possibility to scale manually
- Parameters:
data (dict) – processed ergometer data dictionary with dataframes
title (str, optional) – plotted on top of graph, default is None
height (float, optional) – minimal height of peak, default is 40 N
distance (float, optional) – minimal distance between peaks, default is 500 samples
ylim (list [min, max] of floats or int, optional) – list of the minimal and maximal ylim for user force in N
- Returns:
fig (matplotlib.figure.Figure)
peaks (series) – peaks of maximal user force (averaged over left and right)
- worklab.ana.maximal1min(data, dur, title=None)[source]#
Maximal exercise test analyse. Gives a plot with the power (green) and velocity (red) for each step, also prints the important performance indicators per step:
Work [J] Mean power [W] Maximal power [W] Mean velocity [ms]
- Parameters:
data (dict) – processed and cut ergometer data dictionary with dataframes
dur (int) – duration of max test in seconds
title (str, optional) – title of figure
- Returns:
fig (matplotlib.figure.Figure)
outcomes (dataframe)
- worklab.ana.mean_data(data)[source]#
Combined data of left and right module Time, speed, aspeed, acc and dist are averaged Force, torque, power, work and uforce are averaged and multiplied with two
- Parameters:
data (dict) – processed ergometer data dictionary with dataframes for left and right
- Returns:
data – with left, right and mean module
- Return type:
dict
- worklab.ana.protocol_max(p30, muser, mwc, v=1.39)[source]#
Calculates the protocol for the Maximal exercise test on a wheelchair ergometer, based on the regression equations between the isometric force, anaerobic and aerobic power.
(Janssen T.W.J., Van Oers C.A.J.M., Hollander A.P., Veeger H.E.J., Van der Woude L.H.V. Isometric strength sprint power and anaerobic power in individuals with a spinal cord injury. Med Sci Sports Exercise 1993;25(7):863-870. doi:10.1249/00005768-199307000-00016)
- Parameters:
p30 (float) – average power over a 30-sec Wingate test
muser (float/int) – mass user
mwc (float/int) – mass wheelchair
v (float, optional) – constant comfortable velocity for the test, default is 1.39 m/s
- Return type:
Print the p30, the popeak, the aimed mean velocity and the resistance for each step.
- worklab.ana.protocol_wingate(fiso, muser, mwc, v=2)[source]#
Calculates the protocol for the Wingate test on a wheelchair ergometer, based on the regression equations between the isometric force, anaerobic and aerobic power.
(Janssen T.W.J., Van Oers C.A.J.M., Hollander A.P., Veeger H.E.J., Van der Woude L.H.V. Isometric strength sprint power and anaerobic power in individuals with a spinal cord injury. Med Sci Sports Exercise 1993;25(7):863-870. doi:10.1249/00005768-199307000-00016)
- Parameters:
fiso (float) – maximal 3 seconds force in N, average of left and right
muser (float/int) – mass user
mwc (float/int) – mass wheelchair
v (float/int, optional) – mean velocity wingate, default is 2 m/s
- Returns:
Print the maximal three seconds force, the predicted p30, the aimed mean velocity
and the calculated resistance.
- worklab.ana.wingate(data, title=None, box=False, ylim=5)[source]#
Wingate test analyse. Gives a plot with the power (green) and velocity (red), also prints the important performance indicators
- Parameters:
data (dict) – processed and cut ergometer data dictionary with dataframes
title (str) – title of figure
box (bool) – prints important performance indicators on figure, default is False
ylim (float, optional) – sets the ylim of the graph, default is 5 ms
- Returns:
fig (matplotlib.figure.Figure)
outcomes (dataframe)